Simplicty and flexibility!


DocumentRun("DQLName", "EMail", "pdfname.pdf", "EmailTo", "Subject" , "Body")
DocumentRun(name, "printer", printername)

This is a complimentary function to DocumentOpen(). The reason we have added this new function rather than amend DocumentOpen is due to issues with how its called and wanted functionality in DocumentOpen().

DocumentOpen use Post in WIndows for calling which is "fire and forget". This is ideal when you open a document in WIndows to use but not ideal when you want to produce a number of documents (export,print,pdf,email) in sequence.

DocumentRun() work like RunProcedure() and make sure the document is produced in sequence and finished before the next DocumentRun is executed. This will insure that your PDF generation or email is produced and sent in sequence.





See Also

On the forum about DocumentRun

DocumentRun vs DocumentOpen

The problem with using DocumentOpen for this is that its a "fire and forget" command which can be overridden by other windows command and end the creation early.As DocumentOpen() has many other uses where the "default" POST feature is desireab...

Product: Dataease 9 Developer. Written by DataEase 03/03/23 at 15:39:22

Re:DocumentRun vs DocumentOpen

I see that.It doesnt, however, alter the resulting output, with the PS 3.0 output on one, but the desired PDF 1.7 output on the other. Its this that I really have to sort.Documentrun() will make it easier to work multiple instances like...

Product: Dataease 9 Developer. Written by Paul Cheeseman 03/03/23 at 15:45:31

Re:Re:DocumentRun vs DocumentOpen

Have you had any thoughts on this PS 3.0 creation instead of PDF 1.7 creation?Unfortunately it does stop us using that function....

Product: Dataease 9 Developer. Written by Paul Cheeseman 10/03/23 at 12:18:15

Re:Re:Re:DocumentRun vs DocumentOpen

<img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAA6QAAAMqCAYAAACVBYx1AAAgAElEQVR4nOydeXhURda439vd2cnSYckGmIWouCQmYVEBRwibiOKGM4M6jIqonw4y6nwujMuoIM44nyPq/DCDg4jbDLhHFDCgiAuEEAjKFrMAgSQs2cnWy/390d1Jp9NrFgJ63ufhIX2r6tSpunW769xzqkpRVVVFEARBEARBEAR...

Product: Dataease 9 Developer. Written by DataEase 10/03/23 at 16:14:39

DocumentRun() and printing to a specific printer

Using documentrun() I can succesfully print as I want (email, pdf, printer) until I try to specify which printer to print to.DocumentRun("REP_ReminderPrintForms_PDF","Printer","") works fine, to the default printerDocumentRun("REP_Remind...

Product: Not product specific.. Written by Paul Cheeseman 14/07/23 at 13:58:09

Re:DocumentRun() and printing to a specific printer

Yes, you are correct. We have forwarded the bug to the development team.In the meantime you can use a workaround to set the default printer and re-set it after the print.SetVar("DefaultPrinter",Getcurrent("@DefaultPrinter"))+SetCurrent("...

Product: Dataease 9 Developer. Written by DataEase 17/07/23 at 13:08:23

On the blog about DocumentRun