Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7519491
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T01:54:46+00:00 2026-05-30T01:54:46+00:00

I have an RSS feed parsed into a list view in my app. I’m

  • 0

I have an RSS feed parsed into a list view in my app. I’m trying to make it pull the link for each item in the rss and open it when I click the item in the listview. basicly i have everything already in place but not sure what coding i should use after this statement.

public void onItemClick(AdapterView parent, View view, int position, long id) {

I know that this is where my code should be for opening the url that is saved in the rss file but not sure how to retrieve it from here. Any help is greatly appreciated.

public class MainActivity extends Activity implements OnItemClickListener {

//RSS Feed URL
private final String CGR_FEED_URL = "http://www.mychurchevents.com/Calendar/RSS.ashx?days=7&ci=G1M7G1N8K5G1N8N8H2&igd=";

//XML Widgets
private ListView listview_episodes;
private ProgressBar progress_bar;

@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.main);

    //XML Widgets by ID
    listview_episodes = (ListView) findViewById(R.id.listview_episodes);
    listview_episodes.setOnItemClickListener(this);
    progress_bar = (ProgressBar) findViewById(R.id.progress_bar);
    //Make Progress Bar Invisible
    progress_bar.setVisibility(ProgressBar.INVISIBLE);

    new ArrayList<String>();
    new ArrayList<String>();


    downloadEpisodes(CGR_FEED_URL);

}

private void downloadEpisodes(String Url) {
    //Make Progress Bar Visible While Downloading Feed
    progress_bar.setVisibility(ProgressBar.VISIBLE);
    Log.d("CGRParser", "Downloading Feed");
    //Start an ASync Thread to take care of Downloading Feed
    new DownloadEpisodes().execute(Url);
}

private class DownloadEpisodes extends AsyncTask<String, Integer, ArrayList<Episode>> {

    @Override
    protected ArrayList<Episode> doInBackground(String... url) {

        //Download and Parse Feed
        XmlFeedParser parser = new XmlFeedParser();
        ArrayList<Episode> episodes = new ArrayList<Episode>();
        episodes = parser.parse(url[0]);

        return episodes;
    }

    @Override
    protected void onPostExecute(ArrayList<Episode> result) {

        //Feed has been Downloaded and Parsed, Display Data to User
        Log.d("CGRParser", "Feed Download Complete");
        displayEpisodes(result);

    }

}

private void displayEpisodes(ArrayList<Episode> episodes) {

    //Create String Arrays to seperate titles and dates
    Log.d("CGRParser", "Displaying Episode Titles To User");
    ArrayList<String> episode_titles = new ArrayList<String>();
    ArrayList<String> episode_dates = new ArrayList<String>();
    for (Episode episode : episodes) {
        Log.d("CGRParser", "Episode Title: " + episode.getTitle());
        episode_titles.add(episode.getTitle());
        episode_dates.add(episode.getDate());
    }

    //Create a ListAdapter to Display the Titles in the ListView
    ListAdapter adapter = new ArrayAdapter<String>(this, R.layout.episode_row, R.id.title, episode_titles);
    listview_episodes.setAdapter(adapter);

    //Set Progress Bar Invisible since we are done with it
    progress_bar.setVisibility(ProgressBar.INVISIBLE);

}

public void onItemClick(AdapterView<?> parent, View view, int position, long id) {




}

}
`

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T01:54:47+00:00Added an answer on May 30, 2026 at 1:54 am

    I would just insist to go through this Tutorial and download the complete source and get it working. This will clear up your queries that how it works and also it has included using several XML Parser(SAX, DOM, XmlPullParser, some others) that you will get to learn.

    UPDATE:

    You can use getSelectedItemPosition() and get the selected value from the ListView. And then do the further process of showing the RSS.

    public void onItemClick(AdapterView<?> parent, View view, int position,
                                                                          long id) {
                // get the selected item and do the further process
                listview.getItemAtPosition(position); 
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an RSS feed and I want to integrate each item into it
I have user generated podcasts, each with their own RSS feed. Is there a
I am making an app that parses an RSS Feed into a SQLite database
I have the following code that converts my twitter account rss feed into a
I have a string I have parsed from a RSS feed thumbnail url='http://photos3.media.pix.ie/11/C5/11C5B77C92204ADBBD0CF5FDF4BA351B-0000314357- 0002211156-00240L-00000000000000000000000000000000.jpg'
I'm trying to parse the title tag in an RSS 2.0 feed into three
I'm trying to code an RSS scraper that will pull down a feed and
I am trying to parse an RSS feed with feedparser and insert it into
I have a RSS feed i need to display in a table (its clothes
I have a shared site in sharepoint and have some RSS feed webpart in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.