Simplicty and flexibility!


Function::Memo

PrintMemo
PrintMemo(MemoToPring,Printer,Mode)
PrintMemo(MyMemo,"",1) -- print to default printer, print preview.
retval := PrintMemo(MyMemo,"",3) . -- print to default printer with dialog.


Print the Content of a Memo as formatted HTML. Typical use is when you have used HTMLEditor to create a document stored in a Memo, you use this function to automatically print the content. You can use it anywhere including DQL etc.

Parameters


MemoToPrint 

This is the memo that you want to print. It can be local to the function or you can look it  up via a realtionship.

Printer

This parameter is not yet implemented. It will be implemented so you can either use a Printer name or Printer1-4 (Application Printers).

Mode

0 =  Screenprint (preview) - currently same as 1.
1= Print Preview in Browser object.
2=
Print directly to default printer without dialog.
3=Print Dialogue

Returns/Result


Nothing

Examples


PrintMemo( Body ,"",3)
PrintMemo( Body ,"",0)

Reference

DataEase for Windows printing is concat("CR","AP).

How could a product that was the master of exporting, listing, printing go so completely astray?

As interesting as the answer to that question might be, the answer to the next would be even more interesting..

How come they never fixed it?

Anyhow, this is what we now do. In line with our new strategy of not changing functionality, but adding alternatives, we have now added a way of Printing the content of a Memo directly.

So why would I want to do that?

DataEase Forms are quite good as forms, but they are useless as reports. The format used in DFW is an absolute format, and the printing of this is something called wallpapering. i.e. it is printed WYSIWYG exactly as it is represented on the screen. If it is 0.000001 mm larger than your page, it adds a page to the right etc.

Which crazy person thought this was how the world was going to work in the 21st Century should stop reading Science Fiction comic books, and return to the planet earth.

(The fact that 10mm on a DataEase report is not 10mm on a printer, just add to the exhilaration...read frustration).

They have obviously not be able to fix this or realise the problem over the last 20 years, and we must just assume that it is a good reason for it, and what would happen to all the reports that has been massaged to fit into this crazy framework over the years, if we actually fixed it?

So our conclusion must be, leave it alone and focus on making alternative ways of solving it.

All of this will be history in DG3, but there is a life before DG3 too, and that is our main priority here.

We now use Memo to build documents (HTML or simply text), which you can so print via our WebField object. This way you get a properly formatted document every time, on all printers.

Are we dreaming?

See Also


On the forum about PrintMemo

On the blog about PrintMemo

New Function in 8 - PrintMemo() - Prints the content of a Memo via our WebField object (Ver. 8.0.0.1102)

DataEase for Windows printing is concat("CR","AP).How could a product that was the master of exporting, listing, printing go so completely astray? As interesting as the answer to that question might be, the answer to the next would be ev...

Product: Dataease [{8}]FIVE. Written by DataEase 04/07/12 at 09:13:20


dg3_HelpView