Previous Topic

Next Topic

Report Objects

Report objects can be used to create reports.

Document Print Objects

When a Document Print Object is created using the CreateObject function, a Print Report object with Print Mode B (Batch) is created. For example, the following code shows how to create a batch invoice report object:

Dim printobj as object

printobj = CreateObject("Accredo.INPrintInvoiceReport")

To create a Single Document Print object, create a Print object from the entry form. The following code gives an example of creating a single INPrintInvoiceReport object in the test data.

Dim Form1 as Object

Form1 = CreateObject("Accredo.INInvoiceEntryForm")

form1.Insertinvoice

form1.customercode = "ASHENG"

Dim printobj as object

printobj = form1.print

The Single and Batch object created above will have some different Properties. The properties specific to the Single Print Invoice Report Object are:

EmailSend

You can set a Document Print object to be automatically emailed on Run.

When set to True, when the report is run, it is automatically emailed instead of being shown on screen.

Defaults to False.

EmailTemplateName

The email template to be used when sending the report as an email.

The EmailSend property is available to all Document Print objects that have an EmailTemplateName property.

See Also

MaxBasic Objects

Book Contents

Book Index