04-06-2012, 02:15 PM
Ok, so I have a series of project folders that each contain project files.
I wrote some code to email them using the 'SmtpMail' and mail.AddMessage.
This works well so far but I would like to show the sent messages in my 'SENT' folder.
I realize that QM uses outlook express as the mail utility but I normally use Outlook or gmail if that makes any difference.
My code so far:
I wrote some code to email them using the 'SmtpMail' and mail.AddMessage.
This works well so far but I would like to show the sent messages in my 'SENT' folder.
I realize that QM uses outlook express as the mail utility but I normally use Outlook or gmail if that makes any difference.
My code so far:
SmtpMail mail
Dir d
str filepath
ARRAY(str) filetosend.create(10)
str attachments
int i
int x=0
lpstr folder=dir("C:\Projects\*" 1) ;; get the folder names
rep
,for i 0 10
,,filetosend[i]=0 ;;initialize the array to zeroes
,if(folder = 0) break
,out folder
,x=0
,attachments=NULL
,filepath.from("C:\Projects\" folder "\*")
,foreach d filepath FE_Dir ;;for each file in the folder
,,filetosend[x]=d.FileName(1) ;;get full pathname for the file
,,out filetosend[x]
,,if x=0
,,,attachments.from(filetosend[x] "[]")
,,else
,,,attachments.from(attachments filetosend[x] "[]")
,,x + 1
,out attachments
,mail.AddMessage("[email protected]" folder "Some sample test message text" 1 attachments)
,;;SendMail "[email protected]" folder "Some sample test message text" 1 attachments
,folder=dir("" 1)
mail.Send(0x100)