RogerRuntings
MIS
I am trying to send a Christmas Card email to several thousand customers, using Microsoft Outlook 2K and VFP 6.0,SP5. However, I keep getting an error:
'OLE IDispatch exception code 4096 from Microsoft Outlook.
The system cannot find the file specified.'
code is as follows:
CLOSE DATABASES
CD C:\REMIT\FILES\EXPORT*OPEN DATABASE (HOME( ) + 'ijournal2')
USE ijournal && Opens Customer table
CLEAR
SCAN FOR !EMPTY(addl_info)
*? contact, company, city
o=createobject("outlook.application"
oitem=o.createitem(0)
oitem.subject="Merry Christmas - Paymaster (Ja.) Ltd."
*oitem.to=" "
** To send copy to addresses..
oItem.cc = "technology@paymaster-online.com"
** To send Blind Copy to addresses..
oItem.bcc = addl_info
oitem.body = "You do not need to reply to this email. Your email address is confidential and has not been disclosed to any other party."
** To attach a file
oitem.Attachments.Add("C:\Remit\Files\Export\paymaster-xmax2.jpg"
** to send it
oitem.send
** to clear up
o=.null.
**********************************************************
** EOF **
*Ramani (Subramanian.G), FoxAcc, ramani_g@yahoo.com
ENDSCAN
The error comes up, and the following lines of code are highlighted:
oitem.Attachments.Add("C:\Remit\Files\Export\paymaster-xmax2.jpg"
Can someone shed some light on this situation?
Tomorrow is Christmas Eve...
'OLE IDispatch exception code 4096 from Microsoft Outlook.
The system cannot find the file specified.'
code is as follows:
CLOSE DATABASES
CD C:\REMIT\FILES\EXPORT*OPEN DATABASE (HOME( ) + 'ijournal2')
USE ijournal && Opens Customer table
CLEAR
SCAN FOR !EMPTY(addl_info)
*? contact, company, city
o=createobject("outlook.application"
oitem=o.createitem(0)
oitem.subject="Merry Christmas - Paymaster (Ja.) Ltd."
*oitem.to=" "
** To send copy to addresses..
oItem.cc = "technology@paymaster-online.com"
** To send Blind Copy to addresses..
oItem.bcc = addl_info
oitem.body = "You do not need to reply to this email. Your email address is confidential and has not been disclosed to any other party."
** To attach a file
oitem.Attachments.Add("C:\Remit\Files\Export\paymaster-xmax2.jpg"
** to send it
oitem.send
** to clear up
o=.null.
**********************************************************
** EOF **
*Ramani (Subramanian.G), FoxAcc, ramani_g@yahoo.com
ENDSCAN
The error comes up, and the following lines of code are highlighted:
oitem.Attachments.Add("C:\Remit\Files\Export\paymaster-xmax2.jpg"
Can someone shed some light on this situation?
Tomorrow is Christmas Eve...