|
-
Aug 18th, 2005, 04:22 PM
#1
Thread Starter
New Member
Send to Email recipient in VB
Hi, I need to do the same as Windows Explorer Send to....Email recipient command.
Do you now how?
For ex. I launch a html file using shell command as follow:
Shell "rundll32.exe url.dll,FileProtocolHandler file://" & archivo, vbMaximizedFocus
but I need to do the same to attach a file in new email message....
Thanks.
-
Aug 18th, 2005, 04:27 PM
#2
Fanatic Member
Re: Send to Email recipient in VB
VB Code:
Option Explicit
Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" _
(ByVal hwnd As Long, _
ByVal lpOperation As String, _
ByVal lpFile As String, _
ByVal lpParameters As String, _
ByVal lpDirectory As String, _
ByVal nShowCmd As Long) As Long
private sub MyMail()
ShellExecute 0, "open", "mailto:" & strMessage, "", "", SW_MINIMIZE
end sub
Where strMessage is your html Message with all the proper html markings for TO:, subject, and body.
HTH
Using VB6 or VB.net 2008 with .net 3.5
"Life... death... either way I'll be confined to a small cubicle!" - Hermes Conrad
-
Aug 18th, 2005, 04:32 PM
#3
Re: Send to Email recipient in VB
Also, it would be much easier to open the webpage using ShellExecute. Something like this:
ShellExecute 0, "open", "http://www.google.com", "", "", SW_MAXIMIZE
-
Aug 18th, 2005, 04:38 PM
#4
Thread Starter
New Member
Re: Send to Email recipient in VB
Thanks, but what's up with the attachment?
-
Aug 18th, 2005, 05:20 PM
#5
Re: Send to Email recipient in VB
You mean how to include it automatically uppon shelling?
-
Aug 18th, 2005, 09:08 PM
#6
Addicted Member
Re: Send to Email recipient in VB
This worked for me when I was trying to send email in vb
CLick Here
Jon_G
AKA Phil From Marketing
**************************************
Insert Something Memorable And Witty Here.
**************************************
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|