We have a requirement to generate a csv file from AC4.3 (we can do this) and send this file as an attachment with an email.
Have any of you done this, or have you any suggestion of lines of approach? Many thanks for your time.
Tracey
Jasonic is right, but you could use a VBscript as commandline emailer. This one works for Groupwise and takes 4 parameters: emailadress,subject,body, attachment.
It is rudimentary (pathetic errorchecking), but just to give you an idea:
Dim ToAddress
Dim MessageSubject
Dim MessageBody
Dim MessageAttachment
Dim ol, ns, newMail
Set ol = WScript.CreateObject("Groupwisecommander.Application"
'use the following comment for outlook (untested).
'Set objOutlook = CreateObject("Outlook.Application"
' validate the recipient, just in case...
Set myRecipient = ns.CreateRecipient(ToAddress)
myRecipient.Resolve
If Not myRecipient.Resolved Then
MsgBox "Unknown recipient"
Else
newMail.Recipents.Add(ToAddress)
newMail.Attachments.Add(MessageAttachment).Displayname = "csv"
newMail.Send
End If
Set ol = Nothing
save this as f.i. Postman.vbs and call it like this:
postman.vbs "elvis,presley","don't be cruel",,c:/singalong.txt
You would easily find a better script than this if you 'd google on Outlook.Application
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.