I've been writing a fairly simple RSS Reader... more for practice than any other reason however I found a really interesting problem that I haven't been able to get around.
Most of the feeds work fine and my app is able to pull a list of items. However a couple of feeds do not pull any items. When looking at the raw XML of the feeds they look essentially identical... but in these cases no data (items) are pulled.
To make it a bit more difficult, 2 of the feeds are from the same "blog" site. One works, one doesn't.
Feed yields items
GM-VOLT : Chevy Volt Electric Car Site
Feed does not yield any items
24 boxes
Test app to illustrate this:
Imports System.Xml
Imports System.Net
Imports System.IO
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim myRequest As WebRequest = System.Net.WebRequest.Create("http://feeds.feedburner.com/Gm-volt?format=xml")
'Dim myRequest As WebRequest = System.Net.WebRequest.Create("http://feeds.feedburner.com/24Boxes?format=xml")
Dim myResponse As WebResponse = myRequest.GetResponse()
Dim rssStream As Stream = myResponse.GetResponseStream()
Dim rssDoc As New XmlDocument()
rssDoc.Load(rssStream)
Dim rssItems As XmlNodeList = rssDoc.SelectNodes("rss/channel/item")
MsgBox("item count = " & rssItems.Count)
End
End Sub
End Class
For the first feed (comment/uncomment two test lines) I get a number (usually 10), for the second feed it always returns zero.
Anyone seen this before? Any ideas why I'm getting data from one feed and not the other? The feeds are generated by the same site so I would expect my code to work either way.
Most of the feeds work fine and my app is able to pull a list of items. However a couple of feeds do not pull any items. When looking at the raw XML of the feeds they look essentially identical... but in these cases no data (items) are pulled.
To make it a bit more difficult, 2 of the feeds are from the same "blog" site. One works, one doesn't.
Feed yields items
GM-VOLT : Chevy Volt Electric Car Site
Feed does not yield any items
24 boxes
Test app to illustrate this:
Imports System.Xml
Imports System.Net
Imports System.IO
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim myRequest As WebRequest = System.Net.WebRequest.Create("http://feeds.feedburner.com/Gm-volt?format=xml")
'Dim myRequest As WebRequest = System.Net.WebRequest.Create("http://feeds.feedburner.com/24Boxes?format=xml")
Dim myResponse As WebResponse = myRequest.GetResponse()
Dim rssStream As Stream = myResponse.GetResponseStream()
Dim rssDoc As New XmlDocument()
rssDoc.Load(rssStream)
Dim rssItems As XmlNodeList = rssDoc.SelectNodes("rss/channel/item")
MsgBox("item count = " & rssItems.Count)
End
End Sub
End Class
For the first feed (comment/uncomment two test lines) I get a number (usually 10), for the second feed it always returns zero.
Anyone seen this before? Any ideas why I'm getting data from one feed and not the other? The feeds are generated by the same site so I would expect my code to work either way.