Hello All,
I have created a webpage which uses the following VBScript and then prefills the email with the information and sends it. Why am I doing this? Our Fax Server requires users to use the correct switches and format, and since they are unable to do this, I created an interface thru a webpage which makes it much easier for them. But I do not want them to see the email. I want outlook to send it in the background.
Set WSHShell = CreateObject("WScript.Shell")
Set myOlApp = CreateObject("Outlook.Application")
Set myItem = myOlApp.CreateItem(olMailItem)
myItem.display
myItem.To = ToText
ConstSubject = document.FORM1.txtSubject.value
myItem.Subject= ConstSubject
myItem.Body = chr(13) & chr(13) & ConstComment
myItem.Save
Set myAttachments = myItem.Attachments
myAttachments.Add FileNames
WSHShell.AppActivate myItem
WSHShell.SendKeys ("%(s)")
Thank You.
I have created a webpage which uses the following VBScript and then prefills the email with the information and sends it. Why am I doing this? Our Fax Server requires users to use the correct switches and format, and since they are unable to do this, I created an interface thru a webpage which makes it much easier for them. But I do not want them to see the email. I want outlook to send it in the background.
Set WSHShell = CreateObject("WScript.Shell")
Set myOlApp = CreateObject("Outlook.Application")
Set myItem = myOlApp.CreateItem(olMailItem)
myItem.display
myItem.To = ToText
ConstSubject = document.FORM1.txtSubject.value
myItem.Subject= ConstSubject
myItem.Body = chr(13) & chr(13) & ConstComment
myItem.Save
Set myAttachments = myItem.Attachments
myAttachments.Add FileNames
WSHShell.AppActivate myItem
WSHShell.SendKeys ("%(s)")
Thank You.