?
Solved

C# RSS Screensaver

Posted on 2012-04-12
2
Medium Priority
?
385 Views
Last Modified: 2012-04-23
Hi Experts,

Not sure what would be the best option here so if I explain the situation perhaps you could all offer how you would do this:

I'm building an RSS driven screensaver.  This will ideally pull in the feed content from the published source and then use that to display content.

The consideration I have is that if for any reason the rss feed is not available it still needs to work.  This is most likely to be because a laptop is off the network.

This is what I was thinking:
Build the application and bundle it with images (which are linked to using the RSS <link> tag) and an rss file with the content and a link/filename for each associated image file.

1) On load, download the rss file and copy it to the resources folder.
2) Parse the rss file, find the links to the images and copy them to the resources folder.
3) Run the screensaver using content/images from the now locally stored rss and image files.

If for any reason the rss download fails, use the defaults in the resources folderwhich will be bundled with the exe.

So, if anyone has any thoughts, ideas, suggestions or would like to say I'm plain wrong and have a much better way of doing things, please go for it.

I'm trying to keep this all in one exe as it's a screensaver.

Thanks All!
0
Comment
Question by:ImaCircularSaw
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
2 Comments
 
LVL 22

Accepted Solution

by:
ambience earned 2000 total points
ID: 37845082
Well ... for a sample iPhone/Android RSS reader application I downloaded stuff to a cache (temp folder). If for some reason the update failed the application would display last cached contents (better than nothing) and I could have improved that with some visual indication showing the staleness of contents like a red border with the color brightness a function of number of days the contents stale. I also put an option in the setting to enable the Caching feature and the user could turn it off (again better to control the staleness age like number of days to keep stale data).

So in your case you can show stale contents for up to some configured time and after that if newer contents were still not available you can resort to showing the stock feed.
0
 
LVL 22

Expert Comment

by:ambience
ID: 37845113
Also, its profitable to implement the HTTP cache control mechanisms (not sure whether the HTTP client you are using already supports that). The HTTP cache control uses two properties max-age, max-stale to control client side caching of contents. With RSS, resources are hardly going to be updated very often and images once downloaded will mostly remain the same. Implementing the eTag (Entity Tags) and If-Modified-Since headers along with HTTP caching semantics would be cool. You might as well save that as a reusable component.

If I were to do it, then I would never add temp stuff to resources folder but rather put it in Temp so that the user can delete to conserve space. I hate apps that steal HD space by downloading/caching unwanted stuff to their own folders or even Commons folder. Putting in temp also clearly shows the intentions that this data is temp so feel free to delete without causing irreversible damage to application.

Just my two cents ..
0

Featured Post

Quick Start: DOCKER

Sometimes you just need a Quick Start on a topic in order to begin using it.. this is just what you need to know to get up and running with Docker!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question