Report_SendInMailBody.mdb |
Post Reply |
Author | |
A.D. Tejpal
Microsoft MVP Joined: 30 Jun 2008 Status: Offline Points: 192 |
Post Options
Thanks(0)
Posted: 07 Jul 2008 at 10:49pm |
Report_SendInMailBody This sample db demonstrates sending an access report by placing it in the body of eMail message. Though sending a report as an attachment, using DoCmd.SendObject command is pretty straightforward, including it in the body of eMail itself, requires some extra measures.
Word and Outlook objects are used in this approach and should therefore be available on sender's computer. Two styles are covered, one deals with a single report at a time, while the other provides for sending multiple reports as selected in a list box. Temporary output files are stored in folder named ReportOutput located in the same folder as the sample db. This folder gets created programmatically, if not already existing. An important feature is the display of horizontal lines in final HTML output by using line markers (*^*) in the report. This overcomes a well known limitation otherwise faced in transferring lines from access reports to HTML format. Even though labels with string of hyphens as caption, could be used as replacement for lines, the final results in that case are not quite satisfactory. When an access report is converted to HTML format, it translates to one file per page. While concatenating the contents of these files, care has been taken to eliminate unwanted hyperlink labels (First Previous Next Last) appearing at the bottom of each page. In each case, two alternative modes for transferring the report to mail body are demonstrated: Note: Each time Outlook is used for sending messages programmatically, the user is required to clear a warning message (informing that some program is trying to send a message through Outlook). If manual intervention in this regard is to be circumvented, third party utility like ClickYes could be used. Reference required: Version - Access 2000 file format Download File >>: uploads/37/Report_SendInMailBody.zip |
|
Sponsored Links | Want a good read? Try The Summer of His Life (available on Amazon!) |
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |