Android List view with clickable button

  Рет қаралды 126,809

Android Developer

Android Developer

Күн бұрын

In this video I go over how to make a listview with items that contain clickable buttons. Also dicusses view recycling and the viewholder pattern.
Link to github to download project source code:
github.com/jonndavis1993/Andr...

Пікірлер: 173
@WillDavies973
@WillDavies973 8 жыл бұрын
Awesome tutorial. Been searching for this solution all over for hours on stack overflow and finally found a clear and concise solution.
@MonsieurKonthaar
@MonsieurKonthaar 9 жыл бұрын
Great tutorial, my buttons didn't work while my items did. Now i know why. Thank you!
@c2h7
@c2h7 6 жыл бұрын
Thank you, very helpful! I also searched several sites for hours to find an example for exactly this problem (listview item+button both clickable with id) and this is the simplest and best explained tutorial I've found so far. I'll watch it a couple more times now to get it burned in ;-)
@Brodaty135
@Brodaty135 6 жыл бұрын
Thanks Jonathan! You helped me big time, especially I found useful viewHolder logic in my project.
@MikePlayLD
@MikePlayLD 4 жыл бұрын
Life Saver! Was looking for how to make the button of each item interact with data from that save item. Using this method worked perfectly. Thanks!
@jnavarrob33
@jnavarrob33 7 жыл бұрын
Great tutorial, support and thanks also for sharing the code in GitHub. Nice also that you included the fix for the problem with the item positions.
@biddlecom
@biddlecom 5 жыл бұрын
thank you for mentioning this: android:descendantFocusability="blocksDescendants" Because without that my ListView wasn't responding to clicks (when my button was active). That problem has been killing me for days till I watched your video. THANK YOU!!
@duongtanhung92
@duongtanhung92 5 жыл бұрын
Thank you for this awesome line: android:descendantFocusability="blocksDescendants"
@alirafie5957
@alirafie5957 5 жыл бұрын
looking for more practical tutorials ! That was great
@lars802
@lars802 2 жыл бұрын
Thanks a lot for the best tutorial on KZfaq on this topic!
@marclaliberte4118
@marclaliberte4118 6 жыл бұрын
great tutorial man! in my case the converView was always Null so i had to put my logic accordingly. in any case, thx for the help! works perfectly
@kennedykithome4061
@kennedykithome4061 4 жыл бұрын
Thanks dude!!! You've saved me full week's migraines
@anthonyrobinson6448
@anthonyrobinson6448 5 жыл бұрын
Definitely enjoyed your video, very helpful and you explain the purpose of many lines of code. Thank you!
@CiprianBindiu
@CiprianBindiu 6 жыл бұрын
Thank you for this awesome line: android:descendantFocusability="blocksDescendants". It helped a lot!
@boynextdoor8838
@boynextdoor8838 3 жыл бұрын
If you have a problem about the position keep resetting after 9, the answer: Modify the data if the view is null or not. If the view is null, then deflate and modify the values of the view. If not, the modify the values of the view. Lets just put only 2 lines in the if: if (convertView == null) { LayoutInflater inflater = LayoutInflater.from(getContext()); convertView = inflater.inflate(layout, parent, false); } //Do the remain here The answer is from magallanes, StackOverFlow Thanks to him 👍
@vineethdasi
@vineethdasi 4 жыл бұрын
still an amazing video even after 5 years !!!!!
@gaurav28ch
@gaurav28ch 7 жыл бұрын
Thanks !! Works like a charm with updated code.
@Pro_Znakomstva
@Pro_Znakomstva 8 жыл бұрын
Thank you very much for descendantFocusability! It helped me.
@hadasigal5993
@hadasigal5993 4 жыл бұрын
very good tutorial! I was searching for such solution for long time !
@stosh5494
@stosh5494 7 жыл бұрын
Oh, thank you, you saved my future career)
@albiin900
@albiin900 7 жыл бұрын
Thanks dude! Works perfectly!
@Ztormzz
@Ztormzz 8 жыл бұрын
Amazing tutorial, thank you!
@LiinnkkBR
@LiinnkkBR 7 жыл бұрын
Awesome tutorial. Good Job.
@rentziass
@rentziass 6 жыл бұрын
This is AWESOME, thank you!
@duaneforster
@duaneforster 8 жыл бұрын
Very helpful. Thank you. I'd love to see a video on how to deal with a listview that has a large number of items.
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
+Duane Forster The content in this video applies to list of indefinite length.
@MattBee2k2
@MattBee2k2 8 жыл бұрын
+Duane Forster Encapsulate it inside a Scrollview instead of Relative Layout. Now you can just scroll all the way down to as many list items as there is. I haven't tested it but it seems how it'd work.
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
MattBee2k2 Duane Forster You should never put a ScrollView inside of a ListView. View this link: developer.android.com/reference/android/widget/ScrollView.html
@noemibutton7620
@noemibutton7620 5 жыл бұрын
This helped me a lot! thank you for this video
@Blender3DProjects
@Blender3DProjects 8 жыл бұрын
Wonderful guide, thank you so much :)
@khadijahh1366
@khadijahh1366 4 жыл бұрын
thank you so so much this line helped me ,android:descendantFocusability="blocksDescendants"
@TechProVoice
@TechProVoice 6 жыл бұрын
Wonderful and helpful video, thank you!
@nick8292
@nick8292 8 жыл бұрын
Nice clear tutorial, thanks
@johnsamesky6624
@johnsamesky6624 5 жыл бұрын
thanks so much for this very clear tutorial
@metzUK
@metzUK 8 жыл бұрын
Excellent tutorial, thanks
@alibehboodian7243
@alibehboodian7243 8 жыл бұрын
Wonderful video. Very Helpful.
@nanduraj3355
@nanduraj3355 7 жыл бұрын
Thank you very much.
@pavugi4311
@pavugi4311 5 жыл бұрын
Thank YOU !!!! You are THE BEST !!!
@adnanmomin1185
@adnanmomin1185 7 жыл бұрын
Thanks for video, it really helped allot
@marcosilvacampos6172
@marcosilvacampos6172 9 жыл бұрын
Thank you! you saved my life
@AndroidDeveloper007
@AndroidDeveloper007 9 жыл бұрын
No problem. Please make recommendations for other tutorials and I'll try my best to make one.
@GungEka
@GungEka 8 жыл бұрын
Nice tutorial.
@toxofalger
@toxofalger 8 жыл бұрын
Thanks useful and well explained
@Exclutips
@Exclutips 8 жыл бұрын
How to do it with SQLite data
@WISHALL52
@WISHALL52 5 жыл бұрын
thanks man for the awesome page
@SuperEvoken
@SuperEvoken 8 жыл бұрын
best implementation
@devopsbrain
@devopsbrain 8 жыл бұрын
Thank you man!!!
@multimusingsounds5505
@multimusingsounds5505 7 жыл бұрын
Gracias por el vídeo :3
@Somtqq
@Somtqq 8 жыл бұрын
It works, thank you.
@terrycalafat
@terrycalafat 9 жыл бұрын
You are the best!!!
@boufrioua
@boufrioua 7 жыл бұрын
thanks a lot for your help
@zotta403
@zotta403 5 жыл бұрын
Good Video, Thank you
@ADHDunce
@ADHDunce 5 жыл бұрын
Hi, you saved my life. Also, we accidentally share the same profile picture. Hi fellow DeadPool :D
@minhhaitran7453
@minhhaitran7453 7 жыл бұрын
thank you so much :)
@BigyanChap
@BigyanChap 7 жыл бұрын
Great tutorial!. Thanx. Would you please do a tutorial on Contextual Menu on listView; I wish not to have long press on contextual Menu. I wish just a touch would give me floating Menu. Or may be pop up menu in the listView?
@yeshacroe9354
@yeshacroe9354 4 жыл бұрын
Gosh i realized my brain cant keep up with this video.... way too advance for me....... Me and my stupid brain, thank you sir.
@giorgos1giorgos
@giorgos1giorgos 8 жыл бұрын
In the tutorial at 12:50 when a button is clicked a Toast appears from inside the button's onClick method. But what if we want to return the clicked button's position to the parent activity, so that we call call a method from there?
@monjenvely
@monjenvely 8 жыл бұрын
Hey, why does scrolling down to the bottom of the list change the order of the buttons position to random? the item list doesnt change positions but the delete does, only after scrolling to the bottom/past row 9.
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
what do you mean the buttons position to random?
@monjenvely
@monjenvely 8 жыл бұрын
+Jonathan Davis (iBlacklegend) As in the when u clicked the button ( the number of the position was random/changed). Anyway i fixed it by only bracketing the layoutinflater and convertview in the if(convertView == null) statement and removing the else. Run your code then scroll to the bottom then check the if the number outputted when clicking the list and the button on the same row are the same. For me the Value in buttons were swapped around. eg when i clicked list item in row 1 it would give be position = 0 and when i clicked button in row 1 it would give be position = 0 BUT after i scrolled to the bottom, row 1 list item position was still = 0 and row 1 for button would change to a random value. :/ im horrible at explaining sry
@joeisnotimpressed1506
@joeisnotimpressed1506 8 жыл бұрын
+monjenvely i am facing the same problem! how did you fixed this can you please explain more ?
@pavlus34
@pavlus34 7 жыл бұрын
probably because reused view contained old listener, and displayed text that it was assigned at creation, but when it got reused, the listener hasn't been changed and showed text for it's position in its "previous life".
@ajinkyagaurkar9704
@ajinkyagaurkar9704 7 жыл бұрын
the listener is written in if block ..it should be either in else block or out of the scope of if and else
@shadabanwar2101
@shadabanwar2101 7 жыл бұрын
You did an awesome job!! Thanks a lot... But If I put this two classes in separate file then it want's to declare the viewHolder instance with final keyword which causes problem for me.
@leannebishop7880
@leannebishop7880 4 жыл бұрын
He's a smart man not that I understand this stuff probably
@benedictchin2275
@benedictchin2275 8 жыл бұрын
Hi Jonathan. Thanks for the great tutorial. I wish to implement some data from the database to the android app. I managed to loop and get the data that I wanted by using HTTP Client - Asynctask. However, fetching the data is slower than the creation of the list such that the data is only added to the array list after the list have been created. Hence, no information from database is shown. Is there a way to fetch my data from database before the list is created?
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
Yeah this is very simple to do. One you recieve the data from your database post a runnable using a handler on the UI thread, to set the adapter on the ListView. A better solution is to use a Loader (they were designed for loading data asynchronosly and displaying it to the UI when its finished). There is a very great tutorial by Alex Lockwood that goes into depth on the topic of Loaders and building your own.
@singgihadisaputro
@singgihadisaputro 7 жыл бұрын
Can you set your button with backround tint? I have problem with that, my background tint in button listview did not work, if in general layout worked, i tested in lolipop
@manassingh5351
@manassingh5351 8 жыл бұрын
seems that data is not getting populated in listview as the test next to image is always be "New Text". But it should get changed. Any help on this?
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
+Manas Singh The problem is probably in your getView() method of the list adapter.
@manassingh5351
@manassingh5351 8 жыл бұрын
+Jonathan Davis (iBlacklegend) even in this tutorial the text next to image is not getting populated... it's remaining the same as "New Text" (can be seen in the end of the tutorial when app runs on emulator), even its using some function to generate data.
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
+Manas Singh As was my initial suspicion, the problem was tied to the getView method. The code inside of else bracket, was preventing the textview from having it''s text set. Eventually if you scrolled the list until views started to be recycled and convert view was no longer null you would see the correct text. So to fix the error would be to just remove the else statement brackets from getView so that it is always executed.
@manassingh5351
@manassingh5351 8 жыл бұрын
+Jonathan Davis (iBlacklegend) Thanks a lot, worked great!
@FlameQuantum
@FlameQuantum 8 жыл бұрын
+Manas Singh the code for setting text is missing within the if(convertView == null). That's why no text was set at initiation. Add viewHolder.textView.setText(getItem(position).toString()). Then it should work.
@akshaykumarr7541
@akshaykumarr7541 3 жыл бұрын
Can i start a new activity on button click inside view holder?
@suaybtalhaozcelik6696
@suaybtalhaozcelik6696 6 жыл бұрын
Please help me I can't set the New Text to my firebase mebu ıtem.I can set the New Text in my android stuido manually.However this is not working with firebase.
@ryanjunt3242
@ryanjunt3242 7 жыл бұрын
Is there a way to change the image next to the text in the list and have a different image for each item? thanks
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
Yeah, you can load any image you want, it could even be a video if you'd like. You need to hande the loading logic inside of the getView(...) method.
@kelnhide
@kelnhide 5 жыл бұрын
what listView is ListView lv = (ListView) findViewById(R.id.listview); referencing? there was no list view in the layout file.
@juanvictorbascopecastro1700
@juanvictorbascopecastro1700 4 жыл бұрын
The listView element scrolls very slowly using how do I fix it?
@xrayhunk
@xrayhunk 8 жыл бұрын
Thanks for the educational video. but can you slow a bit down? :/
@yogeshmarathe3018
@yogeshmarathe3018 7 жыл бұрын
i want some items that should not clickable in listview...... how can i do that?
@bullheadrider
@bullheadrider 7 жыл бұрын
There is a problem in this code that when i scroll the items the position gets reset.
@poojapatwa217
@poojapatwa217 7 жыл бұрын
how to use only button in listview to update the badge count which is in action bar???
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
Inside of the OnClick listener of the button manually manipulate the badge counter nested inside of your action bar.
@SunriseSearcher
@SunriseSearcher 6 жыл бұрын
Sorry to wake up an old video, but why every Item on the list is called "New Text" and not like the generated data "This is like number 1..."? How would we go about doing this?
@SunriseSearcher
@SunriseSearcher 6 жыл бұрын
Nevermind found the answer in the comments :)
@musicmix450
@musicmix450 4 жыл бұрын
Hello bro, excelent video!! I have a question, how can I implement a new activity for every button? Example: I clicked one button then the action display a new activity with new information. but in a different button , display a new activity with new information.
@sandeepbaghel9509
@sandeepbaghel9509 6 жыл бұрын
Why generic list contains string type, it should contains button type as we want to make a list of buttons clickable and every button have onclicklistener attach to them. Please explain, thanks in advance
@AzimuthPH
@AzimuthPH 5 жыл бұрын
hello. pls make a tutorial on searching for and highlighting a word in a textview and automatically scroll to the line of the word you are searching for...search widget is on the actionbar. ....there is no tutorial like this on youtube. thank you
@FILMSync
@FILMSync 6 жыл бұрын
How to make fragment transaction inside the onclick listener of button in list view.
@Yes-ok5me
@Yes-ok5me 6 жыл бұрын
when you create another layout to customize the list inside it make fragment as you want inside that layout
@vivekvikani790
@vivekvikani790 8 жыл бұрын
If I have two textviews, how can I set values in both? Thanks in advance!
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
If you store the references in viewholders like I've down with the imageview reference, just use that to set any views properties with appropriate casting where necessary.
@AbikersPOV
@AbikersPOV 8 жыл бұрын
+Jonathan Davis (iBlacklegend) i'm sorry i have the same question. i want to set, example, movie name and movie genre in 1 list item where both have there own textview. In generateListContent(), data.add can only pass 1 value for a text view. how can i pass 2 values for the separate textviews in data when data is an ArrayList of type string? sorry being a newb in advance....
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
+AbikersPOV Instead of a string, you can store a custom item called 'Movie' that has two fields that hold the movie' title and genre. Doing this will allow you to add additional data to the list item in the future if you wish to do so. Some examples would be adding the movie's rottentomato or metacritic score, the movies star rating aggregation, the movies runtime and watched/unwatched flag.
@mph41751
@mph41751 7 жыл бұрын
Great video. I am new to Android. Do you have any code that shows how to update the listview data in this demo for re-display?
@rentziass
@rentziass 6 жыл бұрын
Once you've updated your data source (eg. your array of strings) just call .notifyDataSetChanged() on your adapter
@NicozStrat
@NicozStrat 7 жыл бұрын
Hi, i find helpful your video. Please can you explain me how to add different layout .xml? Thank you
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
In your project explorer right click on the layout folder and select the option "new > Layout Resource file".
@faeezstranger
@faeezstranger 8 жыл бұрын
quite great explanation..Thanks. i have a question..how about if i wanted to get listview area being click out..when should i put the listener?
@faeezstranger
@faeezstranger 8 жыл бұрын
+faeezstranger listView.setOnItemClickListener(new AdapterView.OnItemClickListener() { @Override public void onItemClick(AdapterView parent, View view, int position, long id) { String selected = ((TextView) view.findViewById(R.id.movie_name)).getText().toString(); Toast toast = Toast.makeText(getApplicationContext(),selected,Toast.LENGTH_LONG); toast.show(); } });
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
what do you mean by clicked out?
@faeezstranger
@faeezstranger 8 жыл бұрын
the item on list being click..
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
+faeezstranger I don't really understand your question. If you want to handle list clicks my video should show you how to do that. I have the source code on github also.
@sahilberwal177
@sahilberwal177 6 жыл бұрын
i am not getting what is happening ..in the video and have seen 3,4 videos of similiar kind.Can anybody help..?
@Yes-ok5me
@Yes-ok5me 6 жыл бұрын
yes me too now this happening but when i set onclickleistener nothing happen here the link use baseadapter kzfaq.info/get/bejne/qrKGrZio0rTdoqs.html
@claudedubouzet3043
@claudedubouzet3043 7 жыл бұрын
this would be better if u used string-array values than generate with a fixed value with the same item name.
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
My video is fine as is, but since it so close to Christmas I'll be helpful. Only a simple change is needed to implement what you want. Also using an ArrayList is a good example for the tutorial purpose of this video because it has a very simple interface that is common amongst other collection classes and can easily be switched out with minimum code rewriting.
@AravindanRaj
@AravindanRaj 8 жыл бұрын
Hi, How to pass the list item value to other activity. Could you help me on this. -thanks
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
Pacakge the value inside of a bundle using one of its various typed methods for storing a value and then store the bundle inside of the starting intent for the new activity.
@Yes-ok5me
@Yes-ok5me 6 жыл бұрын
kzfaq.info/get/bejne/aNGFdcaTurOoe3k.html
@technicalhacker6758
@technicalhacker6758 5 жыл бұрын
Give me source code button click to set ringtone in listview button added
@atulkumar9593
@atulkumar9593 7 жыл бұрын
hey Jonathan Davis. very very nice tutorial i wish u could help me out some problem, actually i'm Stuck in some kind of problem which is concerned with two clickable radio button on a listview ,when i scrolled the listview, then all the listview item position is changed as well as the radio button ,so MR. Jonathan could u do that to write this code ..
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
I don't see the problem you're having. Could you explain exactly what is happening when you scroll because all the listview item position is changed as well as the radio button isn't clear.
@atulkumar9593
@atulkumar9593 7 жыл бұрын
+Jonathan Davis (Wade) firstly thanks to replying.. i'll tell the exact problem.. i have a listview and listview contains two radio button one is yes and other is no .. when I'm scrolling my listview and selecting my yes radio button then again I'm scrolling my listview then others radio buttons are automatically selclected ...thts the main problem
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
ATUL VARSHNEY The problem is that the views and their state (such as checked, selected, enabled, disabled etc) are being recycled when you scroll the ListView. You need to manually check whether whatever criteria you are use the radio button represents inside of every call to getView(),
@hanznewton889
@hanznewton889 7 жыл бұрын
GREAT TUTORIAL, VERY HELPFUL. I made a list of buttons, they couldnt fit all on the screen, but I cant scroll down to see the hidden buttons below, PLease how can I achieve that? Also tried making a vertical Linear Layout to implement it, but didn't work, I'll really apreciate how it can be done with a Linear Vertical Layout too.
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
I may be able to help you but just for clarities sake, could you draw a small image of exactly what you're trying to achieve?
@hanznewton889
@hanznewton889 7 жыл бұрын
Basically on the video, no activity launches when you press a button, so how can that be achieved(different buttons, different acitivities launched). Like example, when you fire up an SMS app, a list comes up with all your messages, and you can scroll from top to bottom, so how can i do that???
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
Inside of the views onClick method, do not start a new activity and just leave it blank if you don't want the view to react to clicks.
@georgegallimore6690
@georgegallimore6690 7 жыл бұрын
what IDE is that?
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
george gallimore Android Studio. I'm using a Material Design plug-in.
@javerianadeem745
@javerianadeem745 7 жыл бұрын
Hey any idea why implementing your code is crashing my app on my mobile?
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
It can be any number of things. First check your log cat and see what line is causing the crash.
@javerianadeem745
@javerianadeem745 7 жыл бұрын
Attempt to invoke virtual method 'void android.widget.ListView.setAdapter(android.widget.ListAdapter)' on a null object reference This is what i got in logcat.
@javerianadeem745
@javerianadeem745 7 жыл бұрын
on setAdapter function when pressed Alt+Enter suggests to assert lv!=null.
@tomasvr1
@tomasvr1 7 жыл бұрын
did you create a ListView variable somewhere? if not, then make one. if yes, then you are probably not filling the list with anything to show. you need to give the adapter an array of things (last argument of adapter creation) which the adapter should display in the ListView
@joeisnotimpressed1506
@joeisnotimpressed1506 8 жыл бұрын
Thank You Sir !! this helped me a lot (y) but when i click on a button it doesn't show it's correct position !
@joeisnotimpressed1506
@joeisnotimpressed1506 8 жыл бұрын
+Vikrant Singh that's pretty much it (y) thanks for responding!!
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
+Vikrant Singh +Joe IsNotimpressed I updated the code on github that should fix the incorrect position issue.
@nepalnepali815
@nepalnepali815 7 жыл бұрын
the activities are not so clear due to BLACK background.
@ayrtici95
@ayrtici95 7 жыл бұрын
How can I change the Titles?
@Yes-ok5me
@Yes-ok5me 6 жыл бұрын
set a textview where you want then set a list in array using string then do like what this guy done
@padmabharathi7426
@padmabharathi7426 5 жыл бұрын
my app crashes. please help.
@misterloba7277
@misterloba7277 8 жыл бұрын
Hi. Where can we find source code? Thank you.
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
+MisterLoba Loba I haven't made the source code public. I can add it to github tomorrow.
@johnconnor9787
@johnconnor9787 5 жыл бұрын
Why you did not explain the code that already was in the application? ((((((((((((((
@johncena-hv4rj
@johncena-hv4rj 6 жыл бұрын
Never show what activity_main. Xml contains...
@Yes-ok5me
@Yes-ok5me 6 жыл бұрын
In your project explorer right click on the layout folder and select the option "new > Layout Resource file".
@SassxOxMaster
@SassxOxMaster 7 жыл бұрын
Why do they all say "New Text"? Shouldn't they say whatever is in your data?
@SassxOxMaster
@SassxOxMaster 7 жыл бұрын
When the item scrolls off screen and then back on, it has the correct name. Just wondering why this is the case. Great tutorial btw.
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
There was a bug in my getview() method that caused it my logic to incorrectly choose the wrong indexes from the listview. The code on my GitHub should contain a solution.
@mahidulislammahbub3254
@mahidulislammahbub3254 7 жыл бұрын
hy bro
@dreamin2920
@dreamin2920 7 жыл бұрын
look jonathan github, maybe will be help
@dreamin2920
@dreamin2920 7 жыл бұрын
how to create listview with button click to another activity
@mlsh-azerty
@mlsh-azerty 5 жыл бұрын
so bad we have 3 class in only one java file and we have two clickliner in two différentes classes ane one is in static we cannot call method is very bad
@honzapejsar2639
@honzapejsar2639 7 жыл бұрын
Not working for me
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
Please be more descriptive. What exactly isn't working for you? Are you getting exceptions or is nothing loading when you run the app?
@honzapejsar2639
@honzapejsar2639 7 жыл бұрын
When I run app it crashes. I probably made mistake somewhere
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
What's the logs inside of your logcat when you run the app? Can you post your code to Github and I will take a look at it.
@Suvanch
@Suvanch 4 жыл бұрын
You have to slow down and explain everything. You talk too fast
@flumiie
@flumiie 7 жыл бұрын
talk just a little bit slower, you seemed breathing hard
@jovancerovic2773
@jovancerovic2773 7 жыл бұрын
This SUCKS! NO CODE EXPLANATION!
@gsail1402
@gsail1402 8 жыл бұрын
Crappy tutorial, cant even run my app ... i was trying to see detailed one, but u go over the code like we know all ... in the xml files u never mentioned how to create the list_item.xml or that shit, i was having problem with the activity_main.xml content_list or some shit like that , i wasted like 30 minutes trying to figure it out how to do it ... never had succeed and... u never explain how to modifi a certain quanity of the things in the list ... it seems it autogenerate 6 or 10 items.. bad tut
@AndroidDeveloper007
@AndroidDeveloper007 8 жыл бұрын
+Armando Barreda You are complaining about a tutorial that doesn't fit to your use case. That is very unprofessional and uncalled for. I made this tutorial to be very generic and general purpose, as to teach anyone to implement an enhanced ListView. Your problem seems to be (besides being rude and disrespectful) centered on the fact you don't understand the basics of ListView, and the Android layout system. My video assumes a certain level knowledge to be able to achieve the enhanced ListView.
@Myles_Parker
@Myles_Parker 7 жыл бұрын
This tutorial was very helpful and beneficial even-though it was made years ago, if you dont understand code to a certain degree; dont run your mouth off to someone who has given his time in helping other people understand efficient ways in using list views. Cheers for the tutorial btw(forgot to mention it) :)
@gsail1402
@gsail1402 7 жыл бұрын
TheCheeky901 shut up kid
@Myles_Parker
@Myles_Parker 7 жыл бұрын
Armando Barreda well I can tell that you still can't code
@AndroidDeveloper007
@AndroidDeveloper007 7 жыл бұрын
@Hello, World maybe learn how to do the work on your own. You're criticizing a free tutorial because it doesn't give you all the work you need. As you said it would only take 30 seconds, why don't you make your own video that includes it an unnecessary snippet of making a basic list item. Secondly, I posted all of the code online, so you can just as easily go there and look at it. Of course, I'd be offended by both his and your disrespectful and entitled comments on a video I posted two years old for a class assignment.
ListView in Android Studio using Kotlin | Android Knowledge
9:03
Android Knowledge
Рет қаралды 4 М.
Android Listview Onitemclick Example
22:45
Coding Demos
Рет қаралды 147 М.
DO YOU HAVE FRIENDS LIKE THIS?
00:17
dednahype
Рет қаралды 98 МЛН
Protocol Buffers Crash Course
36:07
Hussein Nasser
Рет қаралды 238 М.
ListView with Images and Text: Android Programming
35:50
Brian Fraser
Рет қаралды 185 М.
ViewModels & Configuration Changes - Android Basics 2023
18:46
Philipp Lackner
Рет қаралды 106 М.
RecyclerView OnClickListener (Best practice way)
11:48
CodingWithMitch
Рет қаралды 291 М.
Working With APIs in Python - Pagination and Data Extraction
22:36
John Watson Rooney
Рет қаралды 96 М.
How to Make ListView | Kotlin | Android Studio
37:06
JonyApps
Рет қаралды 7 М.