Go Back   Android Forums > Android Development > Application Development
Application Development Dev lounge for our application developers.

Get excited for the Samsung Galaxy S5! Find everything you need and discuss it in our Galaxy S5 Forum!

test: Reply
 
LinkBack Thread Tools
Old September 10th, 2009, 03:26 AM   #1 (permalink)
New Member
Thread Author (OP)
 
Join Date: Sep 2009
Posts: 10
 
Device(s):
Carrier: Not Provided

Thanks: 0
Thanked 0 Times in 0 Posts
Default how can i create onItemClickListener

public class VectorPlayList extends ListActivity {
private String[] mStrings = new String[UImediaPlayer.playListForUrl.size()];
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);


setListAdapter(new ArrayAdapter<String>(this,
android.R.layout.simple_list_item_1, mStrings));
getListView().setTextFilterEnabled(true);

for (int i = 0; i < UImediaPlayer.playListForUrl.size(); i++) {
mStrings[i] = (String) UImediaPlayer.playListForUrl.elementAt(i);
// System.out.println(m[i]);
}
}
}
here my code is
now i want to create OnItemClickListener
to my mStrings
how can i
please help me

Leela krishna is offline  
Reply With Quote
sponsored links
Old October 15th, 2009, 08:05 AM   #2 (permalink)
New Member
 
Join Date: Oct 2009
Posts: 4
 
Device(s):
Carrier: Not Provided

Thanks: 0
Thanked 0 Times in 0 Posts
Default

set listitem as clickable and then create a class implementing interface OnClickListener and in this class override method onClick(View v) and by v you can get view which is clicked.
jksharma is offline  
Reply With Quote
Reply


Go Back   Android Forums > Android Development > Application Development
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 03:22 AM.
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.