Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > How to display "No Rss feeds new availabe" when there are no FEEDS

Reply
Thread Tools

How to display "No Rss feeds new availabe" when there are no FEEDS

 
 
Patrick Olurotimi Ige
Guest
Posts: n/a
 
      05-04-2005
I'm using the Function below to get XML feeds
and calling the XML doc in

But if they are no availabe rss feeds i would like to display
"Sorry No Headlines/News at the moment"

Any ideas


page_load like:-

myXml.Document = getXML("http://www.crn.com.au/rss.aspx?SCID=9")

---------------------------------
Function getXML(ByVal sourceFile As String)
Dim myRequest As System.Net.WebRequest =
System.Net.WebRequest.Create(sourceFile)
Dim myResponse As System.Net.WebResponse =
myRequest.GetResponse()
Dim myReader As System.Xml.XmlTextReader = New
System.Xml.XmlTextReader(myResponse.GetResponseStr eam())
Dim doc As System.Xml.XmlDocument = New System.Xml.XmlDocument

doc.Load(myReader)
getXML = doc



myResponse.Close()

myReader.Close()

End Function




*** Sent via Developersdex http://www.developersdex.com ***
 
Reply With Quote
 
 
 
 
clintonG
Guest
Posts: n/a
 
      05-04-2005
At the moment I would suggest researching the use of the AJAX
methodology --- A(synchronous) JA(vascript) X(ml) --- which will allow you
to refresh part of a page without a noticeable trip to the server (no page
flash and no page refresh).

<%= Clinton Gallagher
METROmilwaukee (sm) "A Regional Information Service"
NET csgallagher AT metromilwaukee.com
URL http://metromilwaukee.com/
URL http://clintongallagher.metromilwaukee.com/


"Patrick Olurotimi Ige" <(E-Mail Removed)> wrote in message
news:%(E-Mail Removed)...
> I'm using the Function below to get XML feeds
> and calling the XML doc in
>
> But if they are no availabe rss feeds i would like to display
> "Sorry No Headlines/News at the moment"
>
> Any ideas
>
>
> page_load like:-
>
> myXml.Document = getXML("http://www.crn.com.au/rss.aspx?SCID=9")
>
> ---------------------------------
> Function getXML(ByVal sourceFile As String)
> Dim myRequest As System.Net.WebRequest =
> System.Net.WebRequest.Create(sourceFile)
> Dim myResponse As System.Net.WebResponse =
> myRequest.GetResponse()
> Dim myReader As System.Xml.XmlTextReader = New
> System.Xml.XmlTextReader(myResponse.GetResponseStr eam())
> Dim doc As System.Xml.XmlDocument = New System.Xml.XmlDocument
>
> doc.Load(myReader)
> getXML = doc
>
>
>
> myResponse.Close()
>
> myReader.Close()
>
> End Function
>
>
>
>
> *** Sent via Developersdex http://www.developersdex.com ***



 
Reply With Quote
 
 
 
 
Patrick Olurotimi Ige
Guest
Posts: n/a
 
      05-04-2005
Thanks ClntonG I had a look and it looks interesting alhtough i haven't
tested it yet
Patrick


*** Sent via Developersdex http://www.developersdex.com ***
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Two ways to generate RSS - rss/maker and rss/2.0 - which is better? Jonathan Groll Ruby 1 06-27-2009 03:53 AM
Display RSS feeds rajkm42 ASP .Net 0 03-24-2009 02:37 PM
New RSS Feeds CertGuard A+ Certification 0 04-22-2007 12:59 PM
Is there an easy or Automatic way of doing RSS feeds creation? David D HTML 1 02-28-2007 04:46 AM
Searches in multiple RSS feeds -> new rss feed Motta XML 1 06-09-2004 10:55 PM



Advertisments