|
-
Oct 4th, 2000, 01:17 PM
#1
Thread Starter
Hyperactive Member
Is there a way for me to create a button in my user form that after the file is saved when clicked attaches the file to an email?
Thanks
Thanks Alot,
David Gottlieb
CIW Certified Internet Webmaster
Web Developer/Designer
-
Oct 4th, 2000, 06:55 PM
#2
Fanatic Member
Assuming you are talking about a Word Macro and User Form, this is how you would attach an already saved file using a button on a user form:
Code:
Private Sub cmdSend_Click()
AttachFile ActiveDocument.Path & Application.PathSeparator & ActiveDocument.Name
End Sub
Function AttachFile(tPath)
Set out = CreateObject("outlook.application")
Set myitem = out.CreateItem(0)
myitem.Subject = tPath
myitem.Body = "Here is the attachment you wanted."
myitem.Attachments.Add tPath
myitem.Display
End Function
www.RealisticGraphics.net
Running VS.Net Enterprise & VB 6
Other Languages: JavaScript, VBScript, VBA, HTML, CSS, ASP, SQL, XML
MSN Messenger: kmsheff
-
Oct 5th, 2000, 08:52 AM
#3
Thread Starter
Hyperactive Member
One problem. I am using Novell Groupwise... Is there a way I can do it with that?
Thanks Alot,
David Gottlieb
CIW Certified Internet Webmaster
Web Developer/Designer
-
Oct 5th, 2000, 04:36 PM
#4
Fanatic Member
I don't have any experience with Novell Groupwise. I'm not sure... Maybe create a MAPI session and work through it that way, but like I said, I don't know anything about Novell Groupwise. Try search the web - altavista might be your best bet.
www.RealisticGraphics.net
Running VS.Net Enterprise & VB 6
Other Languages: JavaScript, VBScript, VBA, HTML, CSS, ASP, SQL, XML
MSN Messenger: kmsheff
-
Oct 5th, 2000, 05:01 PM
#5
Thread Starter
Hyperactive Member
I have this code to send an attach this worksheet. It WORKS, but, how can i send to multiple recipients instead of just one. Here is the code I have
Code:
Private Sub btnmail_Click()
ActiveWorkbook.SendMail Recipients:="[email protected]"
End Sub
How can I add one more person to the recipient. Even better, how can I add Carbon Copy (CC) to it instead.
Thanks
Thanks Alot,
David Gottlieb
CIW Certified Internet Webmaster
Web Developer/Designer
-
Oct 6th, 2000, 03:40 PM
#6
Fanatic Member
Not sure about the CC field. Maybe just CC:="whatever". I doubt it though. But in the "To:" line you should be able to insert multiple addresses by seperating them with a semicolon ( . Hope this helps.
www.RealisticGraphics.net
Running VS.Net Enterprise & VB 6
Other Languages: JavaScript, VBScript, VBA, HTML, CSS, ASP, SQL, XML
MSN Messenger: kmsheff
-
Oct 6th, 2000, 03:49 PM
#7
Thread Starter
Hyperactive Member
We tried that but, I figured this out
Code:
ActiveWorkbook.SendMail Recipients:=(range("A1:A2")
Thanx Anyway
Thanks Alot,
David Gottlieb
CIW Certified Internet Webmaster
Web Developer/Designer
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
|