server was unable to process request.--------> object reference not set to an instance of an object
<p>am new in android am doing a web service pgm to get DRUG names here is my code
but getting a problem that server was unable to process request.--------> object reference not set to an instance of an object. can any one slove what is the problem in this</p>

<pre><code>public class DrughandbookActivity extends Activity {

        Button b1;
    EditText atv;
    TextView tv;

     private static final String METHOD_NAME = "DrugSearch";
     private static final String SOAP_ACTION = "https://secure.newcropaccounts.com/V7/webservices/DrugSearch";
     private static final String NAMESPACE = "https://secure.newcropaccounts.com/V7/webservices";
     private static final String URL ="https://secure.newcropaccounts.com/V7/WebServices/Drug.asmx?WSDL";


    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);


    b1=(Button)findViewById(R.id.searchbut);
    atv=(EditText)findViewById(R.id.searchedt);
    tv=(TextView)findViewById(R.id.anstxt);


 b1.setOnClickListener(new View.OnClickListener() {

    @Override
    public void onClick(View arg0) {
        // TODO Auto-generated method stub

        Toast.makeText(getApplicationContext(), "clicked",Toast.LENGTH_LONG).show();

        SoapObject request = new SoapObject(NAMESPACE, METHOD_NAME);

        request.addProperty("DrugName",atv.getText().toString());

        SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);

        envelope.setOutputSoapObject(request);

        envelope.dotNet = true;

        HttpTransportSE ht = new HttpTransportSE(URL);

        try {


            ht.call(SOAP_ACTION, envelope); 

            if (envelope.bodyIn instanceof SoapFault) {
                String str= ((SoapFault) envelope.bodyIn).faultstring;
                Log.i("probs is:", str);

                // Another way to travers through the SoapFault object
            /*  Node detailsString =str= ((SoapFault) envelope.bodyIn).detail; 
                Element detailElem = (Element) details.getElement(0) 
                             .getChild(0); 
                Element e = (Element) detailElem.getChild(2);faultstring; 
                Log.i("", e.getName() + " " + e.getText(0)str); */
            }

            else {

                 SoapObject result = (SoapObject) envelope.getResponse();

                Log.d("WS", String.valueOf(result));
                tv.setText(result.getProperty(0).toString());
            }


        } catch (IOException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } catch (XmlPullParserException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        }

    }
</code></pre>
