Kamis, 10 September 2015

Re: Re: [MS_AccessPros] Re: send email in html format

 

John-
I tried the file you just uploaded. It worked almost perfect, but again, a pop up window appears  "The Sent Items folder is unavailable." and after that another window "Finished, Selected Report Has Been Placed In the OutBox"
Is that possible not to appear these two popups? Thanks!
Kevin

Regards,
Kevin Zhao
 
Date: 2015-09-10 20:42
Subject: Re: [MS_AccessPros] Re: send email in html format
 

Kevin-


See the file that I just uploaded.  Took me about 5 minutes to convert it to not use the libraries.  Also removed the Word capability - just sends HTML.

John Viescas


---In MS_Access_Professionals@yahoogroups.com, <JohnV@msn.com> wrote :

Kevin-

It wouldn't be too hard to modify AD's code to not require the library.  AD's code is much more sophisticated and will handle multiple page reports without having to do any thing funky to force it to one page.

John Viescas, Author
Microsoft Access 2010 Inside Out
Microsoft Access 2007 Inside Out
Microsoft Access 2003 Inside Out
Building Microsoft Access Applications 
SQL Queries for Mere Mortals 
(Paris, France)




On Sep 10, 2015, at 1:25 PM, zhaoliqingoffice zhaoliqingoffice@163.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com> wrote:

John-
Then the code you wrote before sounds more easier, with that I don't need to set reference in outlook, right? I am gonna try your code tonight and let you know how it works. Thank you so much.
Regards,
Kevin



发自我的小米手机
在 "John Viescas JohnV@msn.com [MS_Access_Professionals]" <MS_Access_Professionals@yahoogroups.com>,2015年9月10日 下午5:13写道:

 

Kevin-


Did you import AD's objects into your database, or are you just trying to run the code in his sample database?  In either case, you need to open the VB Editor (CTRL+G will do it), then choose Compile from the Debug menu.  If that gets any errors, you will have to fix them before you proceed.  If you imported AD's objects into your database,  you have to set references in the VBA project to the Outlook and Word libraries on your machine.  Do that from the VB Editor by choosing References from the Tools menu.

Once the code compiles OK, then click the Save button to save the compiled code.  Try running again, and if you still get the same error, then go to the VB Editor and choose Options from the Tools menu.  On the General tab under Error Trapping, choose "Break on All Errors" and then click OK.  Try running the code again - you should see a Debug button on the error dialog, so click that to see the line of code that is failing.  Tell us what that is.

John Viescas, Author
Microsoft Access 2010 Inside Out
Microsoft Access 2007 Inside Out
Microsoft Access 2003 Inside Out
Building Microsoft Access Applications 
SQL Queries for Mere Mortals 
(Paris, France)




On Sep 10, 2015, at 1:16 AM, 'zhaoliqingoffice@163.com' zhaoliqingoffice@163.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com> wrote:

Bill-,
After click on the "sending this report", it returns " 13 - Type mismatch", what shall I do? 
Thanks,
Kevin


Regards,
Kevin Zhao
 
Date: 2015-09-10 04:57
Subject: [MS_AccessPros] Re: send email in html format
 

Kevin


You might find A.D. Tejpal's sample for sending a report in an email body at http://www.rogersaccesslibrary.com/forum/topic52.html
 
 helpful. The man is a genious when it comes to unusual requests.

Regards,
Bill Mosca, Founder - MS_Access_Professionals
Microsoft Office Access MVP
My nothing-to-do-with-Access blog



---In MS_Access_Professionals@yahoogroups.com, <zhaoliqingoffice@163.com> wrote :

Dear All,

I have learnt how to send html as attachment by the code below.


DoCmd.SendObject acSendReport,"rptReport", acFormatHTML,To:= Email here, Subject:=, Message:=False


My question is, is that possible to send html in email content, instead of as attachment?

Many thanks,
Kevin


 




__._,_.___

Posted by: "zhaoliqingoffice@163.com" <zhaoliqingoffice@163.com>
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (27)

.

__,_._,___

Tidak ada komentar:

Posting Komentar