Create an RSS Feed for PDC 2010 videos by ThinqLinq

Create an RSS Feed for PDC 2010 videos

I love the fact that Microsoft makes it’s conference materials available for those unfortunate enough not to be able to attend. I also love watching the videos on my Zune. Even better is when I can use the Zune podcasting ability to download these videos. So far, I wasn’t able to find such a feed. Thankfully, fellow MVP, Bill McCarthy posted some quick LINQ to XML code to generate HTML tables based on the Xessions XML that was used for PDC. You can read his post here:

To take this a step further, I modified his code to generate a quick RSS feed that I can use in the Zune software to download them as if they were a podcast. Here’s the revised code:

Dim doc = XDocument.Load("")
        Response.Write(<?xml version="1.0" encoding="UTF-8"?>
                       <rss version="2.0">
                               <title>PDC Videos</title>
                               <description>Download content files for PDC 2010.</description>
                               <%= From session In doc...<Session>
                                   From content In session...<Content>
                                   Where content.@Url.EndsWith("Low.wmv")
                                   Select <item>
                                              <title><%= session.<ShortTitle>.Value & " - " & content.@Title %></title>
                                              <link><%= session.@ShortUrl %></link>
                                              <enclosure url=<%= content.@Url %>/>
                                          </item> %>


Note: This code does require VB10. If you want to do it with VB9, just add the line continuators (_).

Posted on - Comment
Categories: VB Dev Center - Linq to XML -
comments powered by Disqus