I am attempting to do what I'm sure a lot of Cold Fusion MX 6.1 developers want to do. Connect using the sforce WSDL and do something OTHER than a successful login. What I need in CFML is an equvalent of the following C# code:
private SforceService sForce25 = new SforceService();
ret = sForce25.login(_userName, _password);
sForce25.SessionHeaderValue = new SessionHeader();
sForce25.SessionHeaderValue.sessionId = ret.sessionId;
sForce25.Url = ret.serverUrl;
sForce25.SessionHeaderValue.sessionId = Request.QueryString["sid"].ToString();
Here is what I have so far in CFML:
// create service:
sfapi = CreateObject("webservice", "salesforcewsdlURL");
loginResult = sfapi.login(firstname.lastname@example.org, "password");
Note that I'd like to use the results from the initial login to fuel setting up the sessionID for the subsequent calls. I'm sure someone out there has accomplished this. Note to the moderators - if I can't resolve this issue, it is unlikely that we will decide to purchase the Enterprise version of SalesForce.
I've got my java app running interactively at the DOS command prompt. It logs on to SalesForce, accesses info, etc. just fine. However, when I try to run it in the ColdFusion environment with <CFOBJECT> it dies without a trace (no exceptions thrown) when it attempts to create a SOAP message via the messageFactory,createMessage() method. The message factory object instantiates properly the statement immediately preceding this. I suspect a ColdFusion environment problem, but am not sure. Any suggestions?