AyaNova service management & work order software
AyaNova Support Forum
Home       Members    Calendar    Who's On
Welcome Guest ( Login | Register )
        


AyaNova new email feature for detailed... Expand / Collapse
Author
Message
Posted 1/16/2008 10:23:10 AM
AyaNova Sales & Support

AyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & Support

Group: Administrators
Last Login: Yesterday @ 6:04:54 PM
Posts: 2,018, Visits: 4,604
With AyaNova 4, there is now a new feature that can automatically "suck" out the client's email address if attaching a detailed workroder report to an email, without having to copy it from the client entry screen.

If you have a new installation of AyaNova 4, you will see this in the Sample Detailed Service Workorder with Grand Total report template, or if you have upgraded to AyaNova 4, you can edit your detailed workorder report templates to take advantage of this feature.

To see how this was edited:

1. Open a detailed report template from a workorder in the report designer. For example, open a workorder, select Print, hold down the SHIFT key from your keyboard and select Sample Detailed Service Workorder with Grand Total whic hopens this report template in the report designer)

2. Click on the Detail band for the WorkorderHeader

3. Expand the Scripts property for this band

4. Open up the OnBeforePrint script (in this screenshot it already has the script entered - this is to show you where the script needs to be placed)

5. The script as shown is

private void OnBeforePrint(object sender, System.Drawing.Printing.PrintEventArgs e)
{
xtraReport1.ExportOptions.Email.RecipientAddress = System.Convert.ToString(DetailReport.GetCurrentColumnValue("LT_Client_Label_Email"));

}

6. Save the report template.

7. Now from the workorder entry screen, select Print this detailed report template. When the Print Preview opens, select on the Email menu option. IN our screenshots below, we selected the attachment to be a PDF

8. Save the attachment as a file to your hard drive. You can name the attachment anything you want.

9. Your default email program will open up, automatically entering the client's email address into the TO: field, automatically attaching the report template, and the Subject: will automatically have your computer login name. You can edit as needed now, as well as include your message to your client.

Do note that this feature is available when Print Previewing for a single workorder from that workorder's entry screen.

AyaNova Sales & Technical Support
http://www.ayanova.com
Post #3747
Posted 3/16/2009 6:37:03 PM
AyaNova Sales & Support

AyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & Support

Group: Administrators
Last Login: Yesterday @ 6:04:54 PM
Posts: 2,018, Visits: 4,604
NOTE: There has been a change in the latest version DevExpress printing control for this feature that is used with AyaNova 5.x

To automatically have the email address of the client placed into the TO: of the email message when sending a report as an attachment, the OnBeforePrint script in an AyaNova 5 report template needs to be placed in the OnBeforePrint of the ReportHeader band NOT the Detail1 band.

For example:

1. Open a service workorder for a client that has an email address entered in their client entry screen (such as ABC Accounting if using the sample data)

2. Open the sample report template Sample Detailed Service Workorder with Grand Total in the report designer (hold the SHIFT key on your keyboard while selecting Print -> Sample Detailed Service Workorder with Grand Total )

3. Click on the Detail1 band to select it, and view the OnBeforePrint property for this band

4. As this is no longer used with the printing control with AyaNova 5, you can set this back to its default script

5. Now click on the ReportHeader band to select it

6. View the OnBeforePrint script property for this band, and add to it the line below so that it is between the two { } as per the screenshot below

xtraReport1.ExportOptions.Email.RecipientAddress = System.Convert.ToString(DetailReport.GetCurrentColumnValue("LT_Client_Label_Email"));

7. Test by Print Preview, select Send via Email... select PDF, and this client's email address will now show in the TO: field in the email message you send along with the report as an attachment.

AyaNova Sales & Technical Support
http://www.ayanova.com
Post #4585
Posted 3/27/2009 9:02:02 AM
AyaNova Sales & Support

AyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & SupportAyaNova Sales & Support

Group: Administrators
Last Login: Yesterday @ 6:04:54 PM
Posts: 2,018, Visits: 4,604
ADDITIONAL:  With AyaNova 5, you can instead have the following script in the OnBeforePrint band of the Detail1 band that has the following

private void OnBeforePrint(object sender, System.Drawing.Printing.PrintEventArgs e)
{
DetailBand detail = (DetailBand)sender;
XtraReport report = (XtraReport)detail.Report.Report; // <---- UPDATE THIS LINE depending on what band the script is in

report.PrintingSystem.ExportOptions.Email.RecipientAddress = System.Convert.ToString(DetailReport.GetCurrentColumnValue("LT_Client_Label_Email"));
report.PrintingSystem.ExportOptions.Email.Subject = "Report for Workorder #" + (System.Convert.ToString(DetailReport.GetCurrentColumnValue("LT_O_Workorder")));
}

The above script will place the client's email address into the TO: field in the email message, as well as place the text "Report for Workorder #" and the actual workorder number of the report.



AyaNova Sales & Technical Support
http://www.ayanova.com
Post #4595
« Prev Topic | Next Topic »

Reading This Topic Expand / Collapse
Active Users: 1 (1 guest, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: AyaNova Sales & Support

Permissions Expand / Collapse

All times are GMT -8:00, Time now is 1:10am

Powered by InstantForum.NET v4.1.4 © 2009
Execution: 0.031. 10 queries. Compression Disabled.