Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Software > Commerce Server Solutiionsites > Scriptor Compon...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 1 Topic 265 of 307
Post > Topic >>

Scriptor Component to mail order receipt

by rayeesur@[EMAIL PROTECTED] (csstarter) Aug 25, 2005 at 07:43 PM

I wrote this scriptor componnt to mail receipt to the customers once
they place the order.
Next I added the send mail component to the pipeline and entered the
smtp values and stuff.
When I place an order all i get is a blank email i think its not
capturing the _email_subject and _email_body values from the scriptor
component as I did add these fields in the SMTP component.
What is it Iam doing wrong over here..Am I missing any
thing(registering the scriptor component or anything apart from
this)....
Please help......

function MSC***ecute(config, orderform, context, flags)

    
Dim dataFunctions
	Dim msgBody
Set dataFunctions=context.DataFunctions
	orderform.[_email_subject]="Order Confirmation #: " & _
	orderform.[orderform_id]
	msgBody="Thank you for your order, " & chr(10) & chr(13)
& _
		"Order id : " &orderform.[orderform_id] & chr(10) &
chr(13) & _
		"Order Date : " &
dataFunctions.Date(orderform.[d_DateLastChanged]) & _
		chr(10) & chr(13) & _
		"Order Total : " & _
		dataFunctions.Money(CLng(orderform.[saved_cy_total_total])) & _
		chr(10) & chr(13) & chr(10) & chr(13)
'Loop through ****pping addresses
	Dim ****pments
	****pments=orderform.[****pments]

	msgBody=msgBody & "****pping Addresses" & chr(10) &
chr(13)
	for each ****pment in ****pments
		****ppingAddressid=****pment.[****pping_address_id]
		****ppingAddress=orderform.[Addresses].Value(****ppingAddressid)
	msgBody=msgBody & "****p by :" &
orderform.[****pping_method_name] & _
		chr(10) & chr(13)
	msgBody=msgBody & ****ppingAddress.[address_name] & chr(10)
& chr(13) & _
		****ppingAddress.[address_line1] & chr(10) & chr(13)
	if Len(****ppingAddress.[address2])>0 Then _
	msgBody=msgBody & ****ppingAddress.[address_line2] & chr(10)
& chr(13)
	msgBody=msgBody & ****ppingAddress.[city] & " , " & _
		****ppingAddress.[region_code] & " " &
****ppingAddress.[postal_code] & _
		chr(10) & chr(13) & chr(10) & chr(13)
	next
		orderform.[_email_body]=msgBody 	

MSC***ecute = 1
end function

sub MSCSOpen(config)

end sub[/code]
 




 1 Posts in Topic:
Scriptor Component to mail order receipt
rayeesur@[EMAIL PROTECTED  2005-08-25 19:43:15 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Mon Dec 1 17:45:49 CST 2008.