views:

299

answers:

2

What would be a good way to create a dynamic RSS Feed? Currently, I have coded a function that is able to create a static file, but I am just curious what the best method of running this at certain times/days would be? For example, I create an RSS feed that lists all the items that occur today, and I would like it to populate at 12:01 AM. I also have another RSS feed I wrote that lists the next item to occur.

Just for clarification, I have already created the function to actually make the Feeds, I am just looking for a good way to schedule this process to run on a regular, determinable basis.

I am programming in C# on the .net 3.5 framework in VS 2008.

@John - I am using WebForms, and I don't really have a good reason for not just writing it like that, I just created the static feeds because that was what I knew how to do.

A: 

How about using scheduled tasks for this?

Sam Saffron
This looks nice, but will it work on my web server? It seems like it is for local/network machine jobs. I have also thought about just creating a web service call whenever the pages are loaded, but there are so many places that these feeds will be used that it could create Access Violation Exceptions from multiple attempts to access a file which is already being modified.
Daryl
Then don't give direct access to the file, do it through an aspx that returns the cached file protected by a semaphor while it is being created.
jmservera
A: 

If you have access to the windows scheduler then create a script for that. If not I would create it when the page is first accessed after 12:01 and then use a caching technique for subsequent calls.

jmservera