Tuesday, October 20, 2009


Creating BlackBerry Playlist in C#

I dont have the Media Sync plugin for the Blackberry installed on my laptop yet so I wrote up few lines to create the playlist quickly.

Copy all your music to your blackberry and run the following script in a ASP.NET application.

protected void Page_Load(object sender, EventArgs e)
    StringBuilder sb = new StringBuilder();        
    foreach (FileInfo file in new DirectoryInfo("YourDriveLetter:\\BlackBerry\\music\\Media Sync\\<Your music folder path>").GetFiles())        
        sb.Append("file:///SDCard/BlackBerry/music/Media%20Sync/<Your music folder path>/"+ HttpUtility.HtmlEncode(file.Name));

There you have it.

Labels: , ,

Comments: Post a Comment

<< Home

This page is powered by Blogger. Isn't yours?