function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
AWilkinsonAWilkinson 

Null Pointer Exception

You are connecting to http://na1.salesforce.com/servlet/servlet.SoapApi
SEARCH RESULTS
java.lang.NullPointerException
 at SForce.search(SForce.java:266)
 at SForce.main(SForce.java:394)
Process terminated with exit code 0

 Object result = null;
            SOAPEnvelope respenv = response.getSOAPPart().getEnvelope();
            respbody = respenv.getBody();
         for (Iterator i = respbody.getChildElements(); i.hasNext() {
             SOAPElement element = (SOAPElement) i.next();
             if (element.getElementName().getLocalName().equals(RETURN)) {
                 for (Iterator j = element.getChildElements(); j.hasNext() {
                        SOAPElement next = (SOAPElement) j.next();
                    result = test.api.SForceUtil.getObject(next, this.typeName);

in this section of the code, I am returned with a null pointer exception. I remember reading that others had this same problem, what was the solution?