Munjal Upadhyay
Munjal Upadhyay

Reputation: 189

intent activity is not working properly . Android

http://img861.imageshack.us/img861/7999/64339196.png

I don't understand what the problem is ...

I created so many java and xml file , but never faced this problem ...

in DDMS there is following error ....

http://img822.imageshack.us/img822/352/83236788.png

thanks...

Upvotes: 0

Views: 181

Answers (4)

Munjal Upadhyay
Munjal Upadhyay

Reputation: 189

when I created my class I am going to use that for listing the items ... that is I prepare that class to work for ListView ...

so I extends the ListView .. in my class , in manifest file the class war regestared as ListActivity..

but then , I change my hirarchy , and I don't use the listView in the same class ... but I forget to extends Activity instead of ListActivity ..

that was creating a problem .....

thanks for help....

Upvotes: 0

Brice Durand
Brice Durand

Reputation: 551

The XML layout file for your ListActivity must contain a ListView with

<ListView android:id="@android:id/list"
           android:layout_width="match_parent"
           android:layout_height="match_parent"/>

Upvotes: 0

Shankar Agarwal
Shankar Agarwal

Reputation: 34765

in the image you provided there is no listView but in some xml file you have listview just change the id of that listView.

In the XML file no listview. just change extends ListActivity to extends Activity.

Upvotes: 0

Samir Mangroliya
Samir Mangroliya

Reputation: 40416

if you have Listview in layout change it ...

<ListView android:id="@android:id/list"....></ListView>

if NO,

Than extends Activity

instead of

extends ListActivity

Upvotes: 1

Related Questions