I just received these instructions to send data back to a
Web service. How would I handle this using CF? I changed
around a few things so this is not the actual example.
The following is an example of how to confirm an order
has been shipped.
The receiving method on our end is called
VendorOrderConfirmation and is a web service.
It takes 3 parameters. UnitedDatas Order Number, The date
and time the order was processed/shipped, Fed-Ex/UPS
tracking number, all strings. It will return a boolean
True if successful or False if unsuccessful.
// get the UnitedData Web Service URL from web.config
System.Configuration.AppSettingsReader ar = new
AppSettingsReader(); UnitedDataWS.ReceiveOrder service =
new SIMEPSTestClient.UnitedDataWS.ReceiveOrder();
service.Url = (string)ar.GetValue("SIMEPSServiceLocation",
Type.GetType("System.String", true, true));
// create a SOAP header
UnitedDataWS.AccountInfoHeader aih = new
SIMEPSTestClient.UnitedDataWS.AccountInfoHeader();
// set print vendors credentials
aih.Username = "StPaul";
aih.Password = "Saints";
// add the header to the service
service.AccountInfoHeaderValue = aih;
// The 3 parameters are;
// (UnitedDatas Order Number, The date and time the order
was processed/shipped, Fed-Ex/UPS tracking number) //
Returns True if successful, otherwise False.
Response.Write(service.VendorOrderConfirmation("100",
DateTime.Now,
"1234567890") + "<br>");
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Discover CFTicket - The leading ColdFusion Help Desk and Trouble
Ticket application
http://www.houseoffusion.com/banners/view.cfm?bannerid=48
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:210148
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54