• smilo33
  • NEWBIE
  • 0 Points
  • Member since 2004

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 4
    Replies
I can login using the Getting Started java console example, but I'm not having luck with Tomcat. I created a servlet, but when login is called it keeps getting stuck on RemoteException, but ex.getMessage is always null, so it doesn't tell me what the problem is. I searched google and the message board for days, but I'm completely stuck. Any ideas? Anyone experience this before? Many thanks. ~Samantha

Background:
-- sforce API 4, XP Pro, Tomcat 5.0.18, Axis 1.1, Eclipse 3.0/MyEclipse, jdk 4.0.2.05
-- tried connecting to both: http(s)://www.salesforce.com/services/Soap/c/4.0/
-- Axis libraries were copied to Tomcat's /common/lib
-- tested both http://localhost:8080 & https://localhost:8443 (keytool generated cert was installed). Keep getting the same results. This is not the Handshake problem.

Code segment:

try{
loginResult = binding.login(userName,password);
}
catch(LoginFault ex){
out.println("

Login error: " + ex.getMessage() + "

");
return false;
}

///---PROGRAM DOESN'T GET PAST RemoteException.
///---ex.getMessage() IS ALWAYS NULL

catch(RemoteException ex){
out.println("

Login Remote Host error: " + ex.getMessage() + "

");
return false;
}
////---can't get this far
try{
binding = (SoapBindingStub)
new SforceServiceLocator().getSoap(new URL(loginResult.getServerUrl()));
}
catch(MalformedURLException ex){
out.println("An error: " + ex.getMessage());
return false;
}
catch(ServiceException jre){
out.println("An error: "+ jre.getMessage());
return false;

}
adamg mentioned code having a code example using Javascript/SOAP. Can I see this?

I would like to see how to use MSXML with Javascript to access the API.

Sorry I'm starting a new thread, but I can't tell if the old thread is still getting attention.

Much thanks,

Samantha
Is there any documenation for net.sforce.util.* (EnterpriseLoginBean & ServletEnterpriseLoginBean)? I'm trying to understand how these work in the JSP example, versus the Console sample in the API doc.

The JSP example seems to skip the binding and set endpoint steps of the Console sample. It's a little confusing. I assume these are being taken care of by the bean, but knowing for sure will help me understand each. Also, I would like to know the other methods and properties of the beans.

Thanks.
adamg mentioned code having a code example using Javascript/SOAP. Can I see this?

I would like to see how to use MSXML with Javascript to access the API.

Sorry I'm starting a new thread, but I can't tell if the old thread is still getting attention.

Much thanks,

Samantha