Using RSS Feeds

I'm trying to use an rss feed on my website but can't get it to work. Here is the code behind the webpage:
    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        rssPosts.DataSource = GetRSSFeed("")
    End Sub

    Protected Function GetRSSFeed(ByVal strURL As String) As DataTable
        'Get the XML data
        Dim reader As XmlTextReader = New XmlTextReader(strURL)

        'return a new DataSet
        Dim ds As DataSet = New DataSet()
        Return ds.Tables(2)
    End Function

The result when I run this is an error: A column named 'category' already belongs to this DataTable: cannot set a nested table name to the same name.

I've tried many different rss feeds and all give the same result.

Any help would be greatly appreciated.
Who is Participating?
stullhe104Connect With a Mentor Author Commented:
Thanks for the post. It does show that the rss feed is valid but that didn't help solve my problem.

I solved the problem by using RSSToolKit which I found at:

David H.H.LeeCommented:
Hi stullhe104,
Perhaps you can use online Feed Validator to check the existing RSS file:
David H.H.LeeCommented:
Hi stullhe104,
Ok, you may request admin to refund the points since you already found your own solution.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.