Hi guys, this is a Tutorial to show a list of videos that a user has uploaded to their youtube channel.
YouTube has some great API‘s for using the data from their website and you can retrieve this data in a few formats including XML and JSON. This tutorial will retrieve the data using JSON-C. This gives you the information in key value pairs and having the built in JSON library in android makes it easier and cleaner than having to parse a lot of XML.
So the plan is, talk to YouTube ask them for one users uploaded videos. YouTube will then send back a JSON object that we will retrieve the videos from and shove them into a list, sound easy huh.
What we’re going to do:
- Create an Activity that has a button to initiate the search and a listview to display the results
- Create a new thread that will talk to youtube and retrieve the JSON
- Parse the JSON into nice java objects
- Pass these objects to our ListView and display on the screen
have a look on also
http://www.youtube.com/channel/UCDUdleVTcExA9YOn-jcvfug
https://gdata.youtube.com/feeds/api/videos?author=UCDUdleVTcExA9YOn-jcvfug&v=2&alt=jsonc
to analyze the links.
please download the source code from the link RssFeedforyoutube api's
I have been look for building a fast and feature-rich web application for compitating modern browsers since acquiring TweetDeck in 2011 and the idea of doubling down on the TweetDeck web experience is a reflection of where power users are going.
ReplyDeleteVPN for Android
How to load the listview without pressing the button. I want to load it automatically. Can you help me?
ReplyDeleteHi yes you can do it easily, it is not a big problem
Deleteremove the code for button listener and button from the main layout and directly open the list on ONCREATE METOD.
FOR FURTHER IF YOU WANTS TO MAKE IT FROM ME THAN SEND THE CODE AT UPADHYAY.JITESH@GMAIL.COM
DeleteI want to search by keyword, then what i do, can you provide me a sample for this sir. It's urgent sir.
ReplyDeleteHi Hemant as you needs a search functionality over the list so you can use the blog http://upadhyayjiteshandroid.blogspot.in/2013/02/android-listviewwithsearch.html
DeleteHello jitesh,
ReplyDeleteAmazing post but how can i get the list of videos of my channel and what i have to pass in username in MainActivity..??