locked
Creating RSS reader in Expression blend 4 RRS feed

  • Question

  • Hi everyone, I'm posting this here for two reasons.

     

    1. I'm still a little new at silverlight and at coding so some help is needed.

     

    2. t won't let me post in the expressions forum... don't know why. It says Access denied though so I have to post it here.

     

    I'm trying to create an RSS reader in Expression Blend 4. I looked in the help files and it seems I can make one and I did make a WPF of one. A WPF is fine for what I'm goind because I'm not planning on distributing this on an actual wab page.

     I got the basic setup working. I tested it with the RSS from my twitter account. It works... but the only issue (for now) is that it won't update in realtime.

     Is there someway to make it so that as soon as I post something (or nearly as soon), then it updates?

     I'm also wondering if RSS feeds can be put into different catigories... I think the MSNBC one is sorta like that... like it's all coming from the same feed but one part is for news, one part is for sports... or maybe it's possible to have multiple RSS feeds display news in the same application.

     ... sorta like Twitter does where one person posts one thing, and another person can post something and the last thing posted will move down to reveal the new one.

     

    I haven't tried linking two RSS feeds to one application although I don't see why it couldn't be done, the only thing like I said is that it doesn't update in real time.

     

    Any ideas?

    Again, I'm using Expression Blend 4, so tweaking around the UI won't be a big prblem... just have to jtell the application to do something or play an animation when a new post comes... well that's it, sorry for posting it here, but I can't post in the expressions forum.

     

    Thanks.

    Friday, June 18, 2010 10:57 AM

Answers

  • It's possible to create a Rss Reader with Silverlight

    If you want to get feeds from one other website you need to write a little service that you can host on e.g. SQL Azure e.g.

    Silverlight has also a Timer object that you can use.

    We also asked also the question Is it possible With Silverlight everyhing is possible

    You can see a working example here

    http://www.aptools.net/feed/Reuters.HTML 

     

     

     

     

    Tuesday, June 22, 2010 2:57 PM

All replies

  • The first issue you are going to hit is that in most cases you cant download the RSS feeds, becauce they likely don't have a clientaccesspolicy.xml file on the server. The second issue is that you probably would want to use the WebBrowser control to display the contents of the RSS feed (since this is usually HTML), which will require running the app out-of-browser. Luckily running the app OOB also solves the issue with accessing feeds from other domains, so bottom line is that is the first thing you need to get your app set up.

    Secondly, you have to build a fairly extensive datamodel for this, so I suggest you not only use Expression Blend, but also Visual Studio 2010. Blend is really only good for the design part.

    I'm working on the same type of app (preview here: http://silverlight.sharpgis.net/silverreader). When I get a little further with it and get it cleaned up I do plan on sharing the source on my blog. If you have any specific questions about how I did what, feel free to ask.

    I uses the notification popup feature to notify the user that new feeds has arrived, instead of showing an actual animation as you want. The nice thing about that is that you can have the app minimized and still being notified about new feeds. Again this feature requires running OOB. I also cache a list of feeds that have been read, so the next time the user opens the app, only new unread feeds are highlighted. Basically all I do is to serialize my model to the isolated storage (another benefit of running OOB is that I get 25mb of storage as opposed to the default 1mb).

    Only downside of running OOB is the security warning that the app isn't signed, and I can't do autoupdate. However if I buy a certificate to sign it with (usually $99/year) I can get past those two things. However I'm not planning on going there until my reader is finished.

    Saturday, June 19, 2010 1:46 PM
  • Oh cool tahn ks.

     

    Hm, I don't know TOO Much about coding.

     

    This is going to be an "in house" RSS feed... meaning that it's not going to be a public one so I don't have to worry too much about how it would fare on the web.

     I'm creating an RSS test feed on my machine and am feeding it into silverlight. I'd prefer to have an animation play when a new feed appears though.

     Maybe it's because I don't know too much about writing raw code, but I don't see what's so hard about having it autoupdate, I can already get it to read the rss just fine, I just need it to refresh the post.

     Maybe there's a way I can make the app check for an update every 30 seconds or something.

     Hm, well thanks again for your reply.

    And yes seeing the source for your app would be great. What's it written in? C# or XAML... or both... or.... what?

    Tuesday, June 22, 2010 11:46 AM
  • It's possible to create a Rss Reader with Silverlight

    If you want to get feeds from one other website you need to write a little service that you can host on e.g. SQL Azure e.g.

    Silverlight has also a Timer object that you can use.

    We also asked also the question Is it possible With Silverlight everyhing is possible

    You can see a working example here

    http://www.aptools.net/feed/Reuters.HTML 

     

     

     

     

    Tuesday, June 22, 2010 2:57 PM