Automate export to Outlook

G

Guest

I have a form that on export it creates an excell workbook from the DB and i
would like to know if it is possable to automate the send mail feature of
excell to one email address in code?
DoCmd.OutputTo acOutputQuery, "qrytester", acFormatXLS, _
strPath & "\" & strFile ', 0
DoCmd.TransferSpreadsheet _
TransferType:=acExport, TableName:="qrytester1", _
FileName:=strPath & "\" & strFile,
HasFieldNames:=True
For example the above creates the workbook but the user will have to hit the
mail icon in excell and select an address from outlook. Can this be automated
into one step?--Version 2003
 
G

Guest

Create a test macro. For the action use sendobject. Below you should see
where you can select the object type (table or querey or report) , the object
name, and eventually a TO where you can hard code the e-mail address(s) you
wish it to be sent to. There is also a CC and BCC if you wish to send copies
or blind copies. You can attach the macro to a button on a form and have the
user click on it. The user will still need to click on the send button in
OUTLOOK, but doesn't need to touch the addresses or subject etc.. Try
sending to yourself a report in snap format or a query or table in Excel
spreadhsheet format. Remember there is a record max of 65k approx for a
spreadsheet.
Good Luck
 
D

Dhaval Dave

hi i will be in town till the 18071 it will be a time till the 17th and it
will be query
for the august 17th i am ccoimg back to boston on the saurday evening flight
saturday - evening flight
sunday - 3-4
monday -4-5
tuesday 2-4
wednesday-5-4
thursday 6-4
friday 7-4
1-4
saturday 3-8
sunday 3-4











\
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top