Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP to Outlook
Message
From
08/01/2005 04:34:36
 
 
To
07/01/2005 16:00:52
General information
Forum:
Visual FoxPro
Category:
Third party products
Title:
Miscellaneous
Thread ID:
00975256
Message ID:
00975376
Views:
14
Hi Paul,

the easiest solution in my mind is Outlook Redemption, you can read about it at http://www.dimastr.com/redemption/

>Hello all,
>
>The codes below to send an attached Excel file to Outlook email, it works fine except always me to confirm in Outlook with 2 screens asked :
>
>First screen : from microsoft Outlook
>
>A program is trying to access email-addresses you have stored in Outlook.
>Do you want to allow this ?
>If this is unexpected, it may be a virus and you should choose "No".
>
>Allow access for
>
>YES NO HELP
>----------------------------------------------
>Second screen : from Microsoft OutLook
>
>A program is trying to send automatically send email on your behalf
>
>Do you want to allow this ?
>If this is unexpected, it may be a virus and you should choose "No".
>
>
>YES NO HELP
>
>
>How to get rid of the 2 above screens from Microsoft Outlook ?
>
>Any help or suggestions would be greatly appreciated
>
>Tia
>
>CODES started
>
>*==============================================
>FUNCTION SendExcelFileByMail
>*==============================================
>LOCAL lcProfile, lcPassword, lcExcelFile, lcSubject, lcBody, lcIini_file, lnRecipients, lcbuffer
>LOCAL loApp, loNameSpace, loMailItem
>
>lcProfile 		= ""
>lcPassword 		= ""
>lcSubject 	= "TEST to send Excel File"
>
>lcExcelFile	=  getini("MEM_VAR", "MEM_EXCELFILE", gcIni)
>
>lcbody= " this is a test to send Excel File"
>			>loApp 		= CREATEOBJECT("Outlook.Application")
>loNameSpace	= loApp.GetNameSpace("MAPI")
>loNameSpace.Logon(lcProfile , lcPassword)
>loMailItem 	= loApp.CreateItem(0)
>
>lcRecipient	=getini("MEM_VAR", "MEM_RECIPIENT", gcIni)
>lnRecipients=OCCURS(",", lcRecipient)
>
>IF lnRecipients > 0
>
>	FOR i=1 TO lnRecipients+1
>		DO CASE
>			CASE i=1
>
>				lcbuffer=SUBSTR(lcRecipient,1,AT(",",lcRecipient,i)-1)
>				loMailItem.Recipients.ADD(lcbuffer)
>
>			CASE i=lnRecipients+1
>				lcbuffer=ALLTR(SUBSTR(lcRecipient, AT(",",lcRecipient,i-1)+1))
>				loMailItem.Recipients.ADD(lcbuffer)
>
>			OTHERWISE
>				lcbuffer=ALLTR(SUBSTR(lcRecipient, AT(",",lcRecipient,i-1)+1 ,  ;
>										AT(",",lcRecipient,i)-AT(",",lcRecipient,i-1) -1))
>				loMailItem.Recipients.ADD(lcbuffer)
>		ENDCASE
>	ENDFOR
>ELSE
>	loMailItem.Recipients.ADD(lcRecipient)
>ENDIF
>
>loMailItem.Subject	= lcSubject
>loMailItem.Body 	= lcBody
>
>loMailItem.Attachments.ADD(lcExcelFile, 1, 1, "gamm_active_and_stop")
>
>loMailItem.SEND
>loNameSpace.Logoff
>
>RETURN
>
>
Previous
Reply
Map
View

Click here to load this message in the networking platform