title: error in custom list adapter class
body: <p>I am trying to get server responce and store it in different string array but when i call adapter class till now it is fine but in adapter class will give me error.</p>
  
  <pre><code>    class viewticket extends AsyncTask&lt;String, Void, String&gt; {
  
          @Override
          protected void onPreExecute() {
              super.onPreExecute();
              pdialog = new ProgressDialog(UserLogedIn.this);
              pdialog.setMessage("Loading....");
              pdialog.setIndeterminate(false);
              pdialog.setCancelable(false);
              pdialog.show();
          }
  
          @Override
          protected String doInBackground(String... params)  {
              List&lt;NameValuePair&gt; param = new ArrayList&lt;NameValuePair&gt;();
              param.add(new BasicNameValuePair("userid", u_id));
  
  
              ServiceHandler sh = new ServiceHandler();
  
              // Making a request to url and getting response
              String jsonStr = sh.makeServiceCall(URLMyTicket, ServiceHandler.POST, param);
              Log.d("Response: ", "&gt; " + jsonStr);
              if (jsonStr != null)
  
              {
                  try {
  
                      contacts = new JSONArray(jsonStr);
                      int a=contacts.length();
                      Log.v(TAG,""+a);
                      String[] id = new String[contacts.length()];
                      String[] prob = new String[contacts.length()];
                      String[] desc = new String[contacts.length()];
                      for (int i = 0; i &lt; contacts.length(); i++) {
                          JSONObject c = contacts.getJSONObject(i);
  
                          String aa = c.getString(TAG_ID);
                          String bb = c.getString(TAG_PROB);
                          String cc = c.getString(TAG_DESC);
  
                          Log.v(TAG, "TAG_ID" + aa);
                          Log.v(TAG,"TAGPROB"+bb);
                          Log.v(TAG,"TAGDESC"+cc);
                          id[i] = aa;
                          prob[i]=bb;
                          desc[i]=cc;
                          Log.v(TAG, "aaaaa" + id[i]);
                          Log.v(TAG,"bbbbb"+prob[i]);
                          Log.v(TAG,"ccc"+desc[i]);
                          Ticket_adapter adapter=new Ticket_adapter(this,id,prob,desc);
                          lv.setAdapter(adapter);
                      }
                  } catch (JSONException e) {
                    System.out.print("hiiiiiiiiiiii" );
                      e.printStackTrace();
                  }
              }
              if(jsonStr==null)
              {
                 // Toast.makeText(UserLogedIn.this, "hiiiiiiiiiiiiiiiiiiiii", Toast.LENGTH_SHORT).show();
              }
              return null;
          }
          @Override
          protected void onPostExecute(String  result) {
              super.onPostExecute(result);
              // Dismiss the progress dialog
              pdialog.hide();
              pdialog.dismiss();
          }
  
      }
  </code></pre>
  
  <p>Now the problem in the adapter class that is it give me error at super() method 
      Ticket_adapter.java</p>
  
  <pre><code>    public class Ticket_adapter extends ArrayAdapter&lt;String&gt; {
      UserLogedIn.viewticket context;
      String[] id;
      String[] prob;
      String[] desc;
  
  
      public Ticket_adapter(UserLogedIn.viewticket context, String[] id,String[] prob,String[] desc) {
          super(context, R.id.list_item,id);//error cannot resolve method super
          this.context=context;
          this.id=id;
          this.prob=prob;
          this.desc=desc;
      }
  
  
      @Override
      public View getView(int position, View convertView, ViewGroup parent) {
          LayoutInflater inflater=context.getLayoutInflater();
          View rowView=inflater.inflate(R.layout.my_list, null, true);
  
          TextView idtxt=(TextView)convertView.findViewById(R.id.uid);
          TextView probtxt=(TextView)convertView.findViewById(R.id.prob);
          TextView desctxt=(TextView)convertView.findViewById(R.id.ticket);
  
          idtxt.setText(id[position]);
          probtxt.setText(prob[position]);
          desctxt.setText(desc[position]);
  
  
          return convertView;
  
      }
  }
  </code></pre>
  
  <p>Error:</p>
  
  <blockquote>
    <p>Error:(21, 9) error: no suitable constructor found for
    ArrayAdapter(UserLogedIn.viewticket,int,String[]) constructor
    ArrayAdapter.ArrayAdapter(Context,int,int) is not applicable (argument
    mismatch; UserLogedIn.viewticket cannot be converted to Context)
    constructor ArrayAdapter.ArrayAdapter(Context,int,String[]) is not
    applicable (argument mismatch; UserLogedIn.viewticket cannot be
    converted to Context) constructor
    ArrayAdapter.ArrayAdapter(Context,int,List) is not applicable
    (argument mismatch; UserLogedIn.viewticket cannot be converted to
    Context)</p>
  </blockquote>