If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > PC based Database Applications > Microsoft Excel > How to open email compose window w/ current Excel doc attached?

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 01-22-04, 16:05
MDesigner MDesigner is offline
Registered User
 
Join Date: Jan 2004
Posts: 65
Question How to open email compose window w/ current Excel doc attached?

I have a button that, when clicked, should basically ShellExecute() a mailto:xxx@xxx so that the user's default mailer opens a compose window with subject and body prefilled.. but here's the catch... the current Excel sheet in its current state must be pre-attached to the e-mail.

Is this possible?

Thanks!
Reply With Quote
  #2 (permalink)  
Old 01-22-04, 17:14
Xl-Dennis Xl-Dennis is offline
Registered User
 
Join Date: Dec 2003
Location: Östersund Sweden
Posts: 60
Hi,

What e-mailclient do You use?

Kind regards,
Dennis
__________________
Kind regards,
Dennis
Reply With Quote
  #3 (permalink)  
Old 01-22-04, 17:27
MDesigner MDesigner is offline
Registered User
 
Join Date: Jan 2004
Posts: 65
Outlook. But our clients could be using Outlook Express or some other mailer, we can't hard-code for a specific mail client..
Reply With Quote
  #4 (permalink)  
Old 01-22-04, 19:14
Xl-Dennis Xl-Dennis is offline
Registered User
 
Join Date: Dec 2003
Location: Östersund Sweden
Posts: 60
Hi,

OK, the bad news is that ShellExecute is a simpel mailprotocol that don´t support attachments.

See: ftp://ftp.isi.edu/in-notes/rfc2368.txt

Is MAPI an alternative?

Otherwise You are forced to use a third-part tool for it.

Kind regards,
Dennis
__________________
Kind regards,
Dennis
Reply With Quote
  #5 (permalink)  
Old 01-23-04, 15:07
MDesigner MDesigner is offline
Registered User
 
Join Date: Jan 2004
Posts: 65
I'm not sure how we'd use MAPI.

All I need to do is have a commandbutton open a new mail window with attachments already inserted. But it's sounding like maybe this isn't possible without 3rd party apps? If we DO have to go the 3rd party route, what do you recommend?
Reply With Quote
  #6 (permalink)  
Old 01-23-04, 15:23
shades shades is offline
Registered User
 
Join Date: Oct 2003
Posts: 1,091
This is just a thought. What about having the macro operate from within Excel rather than Outlook? I think this would make the Excel sheet the automatic attachment.
__________________
old, slow, and confused
but at least I'm inconsistent!

Rich
(retired Excel 2003 user, 3/28/2008)

How to ask a question on forums
Reply With Quote
  #7 (permalink)  
Old 01-23-04, 15:32
MDesigner MDesigner is offline
Registered User
 
Join Date: Jan 2004
Posts: 65
Yeah.. I AM working within Excel..that's where the macros are. I know how to get the Excel sheet attached, I think it's SendForReview() or SendMail() or something. Problem is, I also need to allow the user to attach some JPEGs first.. AND I have to set the subject/body to a predetermined block of text (the user does not need to edit it at all).

See how frustratingly complex this is?
Reply With Quote
  #8 (permalink)  
Old 01-23-04, 15:53
shades shades is offline
Registered User
 
Join Date: Oct 2003
Posts: 1,091
Okay, I misunderstood. Not unusual for me.

Just another thought. I had developed a Form in Outlook that included all the addresses plus standard text. I then set up a macro in Outlook and attached to a button on the Outlook toolbar. This allowed the senior managers to click the button, bring up the pre-formatted Outlook message, and all they had to do was manually attach any Excel file. Is this of any help?
__________________
old, slow, and confused
but at least I'm inconsistent!

Rich
(retired Excel 2003 user, 3/28/2008)

How to ask a question on forums
Reply With Quote
  #9 (permalink)  
Old 01-23-04, 16:16
MDesigner MDesigner is offline
Registered User
 
Join Date: Jan 2004
Posts: 65
Well, the process here is kind of the opposite..sort of. They're going to be making lots of changes in an Excel sheet, and want a button within the Excel sheet to send off an email with predefined subj/body, and attach the Excel sheet in its current state along with as many JPEGs as they want to attach.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On