> It is really difficult to read your code, with the Google Groups
> word-wrapping and your commented-out lines.

Sorry, I dont know how to format it. anyway, here it is again,
rectified and without all the comments:


public MyDialog (Context context) {
      super(context);
      this.setTitle(R.string.track_choose);
      participants = new String [2];
      participants[0] = "cimitir";
      participants[1] = "cavou";

      listAdapter = new ArrayAdapter<String> (getContext(),
android.R.layout.simple_expandable_list_item_1, participants);
      participantList = new ListView (getContext());
      LinearLayout.LayoutParams params = new LinearLayout.LayoutParams
(1, 0x77);

      participantList.setLayoutParams(params);
      if (participantList != null && listAdapter != null)
      {
        participantList.setAdapter(listAdapter);
        participantList.setOnItemSelectedListener(this);
      }

      this.addContentView (participantList, params);
}

And about the numerotation starting from 0 :D well ... after 16 hours
of trial and error in a darn slow development as eclipse + android
emulator ...
that was the problem of the nullpointerexception, however, my listview
still behaves the same :(

Thanks
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
Announcing the new M5 SDK!
http://android-developers.blogspot.com/2008/02/android-sdk-m5-rc14-now-available.html
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to