Mobile Zone is brought to you in partnership with:

Michael Crump is a Microsoft MVP, INETA Community Champion, and an author of several .NET Framework eBooks. He speaks at a variety of conferences and has written dozens of articles on .NET development. He currently works at Telerik with a focus on our XAML control suite.
You can visit his blog at: MichaelCrump.Net or follow him on Twitter at: @mbcrump

Michael is a DZone MVB and is not an employee of DZone and has posted 100 posts at DZone. You can read more from them at their website. View Full User Profile

Download all the Microsoft Build Videos with RSS

09.16.2011
| 6069 views |
  • submit to reddit
Introduction

The conference sessions are starting to appear on the Channel 9 RSS feeds right now. If you are like me then you probably want to download all of them and watch them later. Here is the method that I use to grab all the videos and thought that it would help others.

Note: You can use either Juice or PowerShell (which is located at the bottom of this post).

image

 

Let’s do this with Juice

Navigate over to http://channel9.msdn.com/Events/BUILD/BUILD2011/ and select the option to Subscribe to this event:

image

I wanted all Build2011 session in WMV with High quality. (surprising… isn’t it)

That gives me this URL: http://channel9.msdn.com/Events/BUILD/BUILD2011/RSS/wmvhigh

I can plus that into my browser and see the following:

image

But if you click on one of them then it just takes you to the page:

image

I could care less about this page as I only want the videos and I may not have an internet connection later on.

Let’s solve this

Step 1- Download Juice and run the installer.

Step 2 – Once it is installed then hit the Add Button.

SNAGHTML6e84953

Step 3 – Copy and Paste the URL of the feed you want to download.

SNAGHTML6e90aae

Step 4 – That’s it. You are ready to start downloading. Please note that the files that have a 0.0 MB have not been added to the feed yet. Give it a day or so and it should appear. 

SNAGHTML6ea5a34

If you really don’t want to install juice software then you can use PowerShell.

Let’s do this with PowerShell

The good news is that if you are using Windows 7 right now then you already got PowerShell installed.

Go ahead and create a folder somewhere on your computer named: Build11. If you want to follow my example then just put it on the root of C:

Now open up your favorite text editor and copy/paste the following code:

cd "C:\build11"
[Environment]::CurrentDirectory=(Get-Location -PSProvider FileSystem).ProviderPath
$a = ([xml](new-object net.webclient).downloadstring("http://channel9.msdn.com/Events/BUILD/BUILD2011/RSS/wmvhigh"))
$a.rss.channel.item | foreach{ 
    $url = New-Object System.Uri($_.enclosure.url)
    $file = $url.Segments[-1]
    $file
    if (!(test-path $file))
    {
        (New-Object System.Net.WebClient).DownloadFile($url, $file)
    }
}

Note: The PowerShell script code is taken from a post by Scott Hanselman and variations of it exist all over the web.

Go ahead and save the file as downloadall.ps1.

You should have a folder named build11 and one file in it named downloadall.ps1.

image

The only thing you will need to do now is go to a command prompt and type “powershell”.

SNAGHTML6f7afc3

Navigate over to the directory you created earlier. I created one called build11.

Once you have navigated over to it, do a “dir” to see the contents. If you see your downloadall.ps1 script then your good to go.

SNAGHTML6fd176b

Enter the command ./downloadall.ps1

If your having trouble actually running that command then refer to this post.

SNAGHTML6fdd58b

Give it a few minutes (depending on your internet connection) and the files should start appearing in your build11 folder.

image

Conclusion

I hope this guide cleared up some of the confusion that people had with downloading all of the videos.

References
Published at DZone with permission of Michael Crump, author and DZone MVB. (source)

(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)