Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Amyuni email
Message
From
06/02/2012 16:40:18
Stan Vaninger
Mitek Industries, Inc
Missouri, United States
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Third party products
Title:
Amyuni email
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Mobile
Miscellaneous
Thread ID:
01534589
Message ID:
01534589
Views:
113
Here is some code we are using to create an email using Amyuni:
IF This.Parent.LogSession	&& Check if the user was able to login.
	This.Parent.OleMMess.sessionid = This.Parent.OleMSess.sessionid

	* Start a new mail message and build the text.
	This.Parent.OleMMess.Compose
	This.Parent.OleMMess.msgnotetext = tcMessage
	This.Parent.OleMMess.msgsubject	= tcSubject
	
	This.Parent.OleMMess.AttachmentIndex = m.iCounter - 1
	This.Parent.OleMMess.AttachmentCount = m.iCounter
	This.Parent.OleMMess.AttachmentName = JUSTFNAME(tcOutputFile)
	This.Parent.OleMMess.AttachmentPathname = ALLTRIM(tcOutputFile)
	This.Parent.OleMMess.AttachmentPosition = m.iCounter - 1

	Thisform.oMailBtn.olemmess.RecipIndex = 0
	Thisform.oMailBtn.cDefaulteMailAddress = ALLTRIM(thisform.edtTo.Value)

	m.iCounter = 0
	ceMailTo = This.Parent.cDefaulteMailAddress
		
	DO WHILE !EMPTY(ceMailTo)
		This.Parent.OleMMess.Recipindex = m.iCounter
		iCounter = 	m.iCounter + 1
		iBegPosition = 1
		iEndPosition = IIF(ATC(";",m.ceMailTo)=0,LEN(m.ceMailTo),ATC(";",m.ceMailTo)-1)

		This.Parent.OleMMess.Recipdisplayname = ALLTRIM(SUBSTR(m.ceMailTo,m.iBegPosition,m.iEndPosition))
		ceMailTo = IIF(ATC(";",m.ceMailTo)=0,"",SUBSTR(m.ceMailTo,ATC(";",m.ceMailTo)+1))	&& Strip off the address just processed.
	ENDDO

	This.Parent.OleMMess.Send(1)
	IF This.Parent.LogSession
		This.Parent.OleMSess.Signoff
	ENDIF	&& Session Handle test
ENDIF
This code works but only fills in the To: line with the email addresses in the ceMailto string. We also want to fill in the CC: and BCC: lines with other email addresses.

I have done some testing and found that changing the property: OleMMess.recipType = 2 fills in the CC: line but then the To: line is empty.

How can all three lines be filled in (To:, CC:, and BCC:)?

Thanks very much,
Stan
Reply
Map
View

Click here to load this message in the networking platform