<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.com.pk/utility/FeedStylesheets/atom.xsl" media="screen"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en"><title type="html">ASP.NET Applications</title><subtitle type="html">Discuss and share about ASP.NET Development</subtitle><id>http://weblogs.com.pk/blogs/aspnet/atom.aspx</id><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/default.aspx" /><link rel="self" type="application/atom+xml" href="http://weblogs.com.pk/blogs/aspnet/atom.aspx" /><generator uri="http://communityserver.org" version="2.1.61129.2">Community Server</generator><updated>2009-01-06T01:16:00Z</updated><entry><title>Google Malware Warnings Right Now ... OR .....</title><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/archive/2009/01/31/google-malware-warnings-right-now-or.aspx" /><id>http://weblogs.com.pk/blogs/aspnet/archive/2009/01/31/google-malware-warnings-right-now-or.aspx</id><published>2009-01-31T15:10:00Z</published><updated>2009-01-31T15:10:00Z</updated><content type="html">&lt;P&gt;&lt;STRONG&gt;&lt;FONT size=4&gt;UPDATE:&lt;/FONT&gt;&lt;/STRONG&gt; A&amp;nbsp;data entry glitch by a Google employee led to this. Read about it here: &lt;A class="" href="http://technology.timesonline.co.uk/tol/news/tech_and_web/the_web/article5627321.ece" target=_blank&gt;'Human error' shuts down&amp;nbsp; Google&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;Is something up with Google? Every single search that I do shows a malware warning (even sites like microsoft.com). Is there something wrong, or something's up with my computer.&lt;/P&gt;
&lt;P&gt;&lt;IMG title="Google Malware Warning on every search result" border=1 alt="Google Malware Warning on every search result" src="http://www.ecubicle.net/google_error.jpg" width=1280 height=800&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://weblogs.com.pk/aggbug.aspx?PostID=139508" width="1" height="1"&gt;</content><author><name>aspnet</name><uri>http://weblogs.com.pk/members/aspnet.aspx</uri></author><category term="google" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/google/default.aspx" /></entry><entry><title>ASP .NET Client Callbacks</title><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/archive/2009/01/28/asp-net-client-callbacks.aspx" /><id>http://weblogs.com.pk/blogs/aspnet/archive/2009/01/28/asp-net-client-callbacks.aspx</id><published>2009-01-28T05:56:00Z</published><updated>2009-01-28T05:56:00Z</updated><content type="html">&lt;P&gt;
&lt;OBJECT height=364 width=445&gt;&lt;PARAM NAME="movie" VALUE="http://www.youtube.com/v/hdv3vOfbSfs&amp;amp;hl=en&amp;amp;fs=1&amp;amp;color1=0x3a3a3a&amp;amp;color2=0x999999&amp;amp;border=1"&gt;&lt;PARAM NAME="allowFullScreen" VALUE="true"&gt;&lt;PARAM NAME="allowscriptaccess" VALUE="always"&gt;
&lt;embed src="http://www.youtube.com/v/hdv3vOfbSfs&amp;hl=en&amp;fs=1&amp;color1=0x3a3a3a&amp;color2=0x999999&amp;border=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="445" height="364"&gt;&lt;/embed&gt;&lt;/OBJECT&gt;&lt;/P&gt;
&lt;P&gt;And, here are the links to the remaining three parts of the video. Seriously, time limit on YouTube videos should realistically be around 15-20 mts.&lt;/P&gt;
&lt;P&gt;&lt;A class="" href="http://ca.youtube.com/watch?v=BLSrTj0zaH8&amp;amp;feature=channel_page&amp;amp;fmt=18" target=_blank&gt;Part 2 of 4&lt;/A&gt;&amp;nbsp;| &lt;A class="" href="http://ca.youtube.com/watch?v=YTyLM2VC4C4&amp;amp;feature=channel_page&amp;amp;fmt=18" target=_blank&gt;Part 3 of 4&lt;/A&gt;&amp;nbsp;| &lt;A class="" href="http://ca.youtube.com/watch?v=Wpn_vJtQ3Io&amp;amp;feature=channel_page&amp;amp;fmt=18" target=_blank&gt;Part 4 of 4&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://weblogs.com.pk/aggbug.aspx?PostID=139066" width="1" height="1"&gt;</content><author><name>aspnet</name><uri>http://weblogs.com.pk/members/aspnet.aspx</uri></author><category term="youtube" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/youtube/default.aspx" /><category term="xml" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/xml/default.aspx" /><category term="icallbackeventhandler" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/icallbackeventhandler/default.aspx" /><category term="callback" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/callback/default.aspx" /></entry><entry><title>Converting non-English videos into English Using .NET Framework</title><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/archive/2009/01/20/converting-non-english-videos-into-english-using-net-framework.aspx" /><id>http://weblogs.com.pk/blogs/aspnet/archive/2009/01/20/converting-non-english-videos-into-english-using-net-framework.aspx</id><published>2009-01-20T23:51:00Z</published><updated>2009-01-20T23:51:00Z</updated><content type="html">&lt;p&gt;In a bid to make my videos more accessible to a global audience, I came with an&amp;nbsp;idea to use System.Speech classes to convert the audio tracks on my videos into English using Speech Synthesis provided by the .NET Framework.&lt;br&gt;&lt;br&gt;Here is some sample code in a Windows Forms Application. Code is written in the Button click event handler. &lt;b&gt;Requires imports statement for System.Speech and System.Speech.Synthesis.&lt;/b&gt;&lt;br&gt;&lt;/p&gt;
&lt;font face="book antiqua,palatino"&gt;&lt;b&gt;&lt;font color="#990000"&gt;&lt;div style="border:1px solid black;margin:5px;padding:15px;overflow:scroll;width:95%;"&gt;Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim mySpeech As New SpeechSynthesizer()&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; mySpeech.SelectVoice("Microsoft Anna")&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; mySpeech.Volume = 100&lt;br&gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim myList As New List(Of String)&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; myList.Add("Today, we learn how to convert non-English videos into English using .NET Speech Classes")&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; myList.Add("If your video is not in English, and, you would like to make it accessible to a global audience in the English language, then, ")&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; myList.Add("we can use a trick to convert the videos into English.")&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; myList.Add("We will make use of System.Speech namespace in this program and see how this all ties up.")&lt;br&gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; mySpeech.SetOutputToWaveFile("d:\6.wav")&lt;br&gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; For Each myItem As String In myList&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; mySpeech.Speak(myItem)&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Next&lt;br&gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; mySpeech.SetOutputToDefaultAudioDevice()&lt;br&gt;&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; mySpeech.Speak("File Saved")&lt;br&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; End Sub&amp;nbsp;&lt;/div&gt;
&lt;/font&gt;&lt;/b&gt;&lt;/font&gt;
&lt;p&gt;Though still haven't tried it, but importing the audio into Windows Movie Maker and then merging it with my existing videos should work and create a new movie file with an English track. &lt;br&gt;&lt;br&gt;I have still to learn more about the Speech API and to make the voice sound more human (though, the Microsoft Anna voice is rather brilliant, I must admit). It is only on certain occassions that the voice falls short of the intended mood+pitch - which I think could be addressed with some of the other classes in the Speech API. &lt;br&gt;&lt;/p&gt;&lt;img src="http://weblogs.com.pk/aggbug.aspx?PostID=138216" width="1" height="1"&gt;</content><author><name>aspnet</name><uri>http://weblogs.com.pk/members/aspnet.aspx</uri></author><category term="youtube" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/youtube/default.aspx" /><category term="speech" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/speech/default.aspx" /></entry><entry><title>MSDN Hackable URL's</title><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/archive/2009/01/18/msdn-hackable-url-s.aspx" /><id>http://weblogs.com.pk/blogs/aspnet/archive/2009/01/18/msdn-hackable-url-s.aspx</id><published>2009-01-18T06:43:00Z</published><updated>2009-01-18T06:43:00Z</updated><content type="html">&lt;P&gt;Here is a neat trick that always comes in handy when looking for a quick reference on classes and their members in .NET. MSDN URL's are hackable; they can simply be called as follows:&lt;/P&gt;
&lt;P&gt;&lt;A href="http://msdn.microsoft.com/en-us/library/system.net.networkinformation.networkinterface.getisnetworkavailable.aspx"&gt;http://msdn.microsoft.com/en-us/library/system.net.networkinformation.networkinterface.getisnetworkavailable.aspx&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;The above returns the page with information about the GetIsNetworkAvailable method in Networkinterface class of System.Net.Networkinformation namespace.&lt;/P&gt;
&lt;P&gt;So, for example, you need a reference on ASP. NET Membership class (System.Web.Security). Here is the URL:&lt;/P&gt;
&lt;P&gt;&lt;A href="http://msdn.microsoft.com/en-us/library/system.web.security.membership.aspx"&gt;http://msdn.microsoft.com/en-us/library/system.web.security.membership.aspx&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;So, if you know of a class and/or its members, reference is just a click away.&lt;/P&gt;&lt;img src="http://weblogs.com.pk/aggbug.aspx?PostID=137943" width="1" height="1"&gt;</content><author><name>aspnet</name><uri>http://weblogs.com.pk/members/aspnet.aspx</uri></author><category term="msdn" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/msdn/default.aspx" /></entry><entry><title>Httpmodules: App Level IP Address Filtering</title><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/archive/2009/01/15/httpmodules-app-level-ip-address-filtering.aspx" /><id>http://weblogs.com.pk/blogs/aspnet/archive/2009/01/15/httpmodules-app-level-ip-address-filtering.aspx</id><published>2009-01-15T15:52:52Z</published><updated>2009-01-15T15:52:52Z</updated><content type="html">&lt;div style="padding-right:0px;padding-left:0px;padding-bottom:0px;margin:0px;padding-top:0px;display:inline;" id="scid:5737277B-5D6D-4f48-ABFC-DD9C333F4C5D:dcfdafbe-d33a-47d8-8541-5571b2a355eb" class="wlWriterSmartContent"&gt;&lt;div id="e887212e-b67b-4b54-93d6-c6ffa3c3a78c" style="margin:0px;padding:0px;display:inline;"&gt;&lt;div&gt;&lt;a href="http://www.youtube.com/watch?v=ytMSI1-aJfM" target="_new"&gt;&lt;img src="http://weblogs.com.pk/blogs/aspnet/WindowsLiveWriter/HttpmodulesAppLevelIPAddressFiltering_98ED/videoe6d901acfd25.jpg" alt=""&gt;&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;img src="http://weblogs.com.pk/aggbug.aspx?PostID=137565" width="1" height="1"&gt;</content><author><name>aspnet</name><uri>http://weblogs.com.pk/members/aspnet.aspx</uri></author><category term="linq" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/linq/default.aspx" /><category term="xml" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/xml/default.aspx" /><category term="httpmodules" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/httpmodules/default.aspx" /><category term="web.config" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/web_2E00_config/default.aspx" /></entry><entry><title>App Level IP Address Filtering: HttpModules</title><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/archive/2009/01/14/app-level-ip-address-filtering-httpmodules.aspx" /><id>http://weblogs.com.pk/blogs/aspnet/archive/2009/01/14/app-level-ip-address-filtering-httpmodules.aspx</id><published>2009-01-14T23:06:00Z</published><updated>2009-01-14T23:06:00Z</updated><content type="html">&lt;P&gt;How to work with httpmodules. I tried to embed a video but it does not get rendered on the blog post. Neither does this version of CS have add media option. Can someone let me know how to embed youtube videos here? Thanks!&lt;/P&gt;
&lt;P&gt;Finally, here are the links to my recent video tutorials on httpmodules and how to work with application level IP address filtering.&lt;/P&gt;
&lt;P&gt;Part 1: &lt;A href="http://ca.youtube.com/watch?v=ytMSI1-aJfM&amp;amp;fmt=18"&gt;http://ca.youtube.com/watch?v=ytMSI1-aJfM&amp;amp;fmt=18&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Part 2: &lt;A href="http://ca.youtube.com/watch?v=G_4__HdG4PA&amp;amp;fmt=18"&gt;http://ca.youtube.com/watch?v=G_4__HdG4PA&amp;amp;fmt=18&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Part 3: &lt;A href="http://ca.youtube.com/watch?v=AOIUdCLBP9I&amp;amp;fmt=18"&gt;http://ca.youtube.com/watch?v=AOIUdCLBP9I&amp;amp;fmt=18&lt;/A&gt;&lt;/P&gt;&lt;img src="http://weblogs.com.pk/aggbug.aspx?PostID=137485" width="1" height="1"&gt;</content><author><name>aspnet</name><uri>http://weblogs.com.pk/members/aspnet.aspx</uri></author><category term="youtube" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/youtube/default.aspx" /><category term="linq" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/linq/default.aspx" /><category term="filtering" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/filtering/default.aspx" /><category term="httpmodules" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/httpmodules/default.aspx" /><category term="web.config" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/web_2E00_config/default.aspx" /></entry><entry><title>280slides.com - Web Presentation App</title><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/archive/2009/01/11/280slides-com-web-presentation-app.aspx" /><id>http://weblogs.com.pk/blogs/aspnet/archive/2009/01/11/280slides-com-web-presentation-app.aspx</id><published>2009-01-11T08:00:00Z</published><updated>2009-01-11T08:00:00Z</updated><content type="html">&lt;P&gt;Interesting Web App to create presentations. The whole UI feels like a desktop environment. It is coded in a language called Objective-J.&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.280slides.com/"&gt;http://www.280slides.com&lt;/A&gt;&lt;BR&gt;&lt;/P&gt;&lt;img src="http://weblogs.com.pk/aggbug.aspx?PostID=137105" width="1" height="1"&gt;</content><author><name>aspnet</name><uri>http://weblogs.com.pk/members/aspnet.aspx</uri></author><category term="objective j" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/objective+j/default.aspx" /></entry><entry><title>Google Search RSS Feeds</title><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/archive/2009/01/09/google-search-rss-feeds.aspx" /><id>http://weblogs.com.pk/blogs/aspnet/archive/2009/01/09/google-search-rss-feeds.aspx</id><published>2009-01-09T22:55:00Z</published><updated>2009-01-09T22:55:00Z</updated><content type="html">&lt;p&gt;Here is my attempt to transform Google Search Results into a RSS feed. This functionality is missing from Google. Test it out and provide some feedback. I have published the feed as a web service at&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.ecubicle.net/gsearch_rss.asmx" title="http://www.ecubicle.net/gsearch_rss.asmx"&gt;http://www.ecubicle.net/gsearch_rss.asmx&lt;/a&gt;&lt;/p&gt;&lt;p&gt;There is a single function called GetSearchResults with the following signature&lt;/p&gt;&lt;p&gt;&lt;b&gt;GetSearchResults(byval searchPage As string, byval gQuery As String, byval numOfResults As String)&lt;/b&gt;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;searchPage provides the google search page that runs in multiples of 10 with 10 results each page (default on Google). The value for first page is 0&lt;/li&gt;&lt;li&gt;gQuery is google query. You can use any set of Google operators here to tune the query&lt;/li&gt;&lt;li&gt;numOfResults is the number of results to return per page. Default is 15.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;The returned XML is RSS 2.0 compliant. As such, any feed reader can also read the returned XML document.&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;font size="4"&gt;&lt;b&gt;Using in a Feed Reader&lt;/b&gt;&lt;/font&gt; &lt;/p&gt;&lt;p&gt;To call this in a feedreader, here is the GET syntax for the web service&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.ecubicle.net/gsearch_rss.asmx/GetSearchResults?searchPage=0&amp;amp;gQuery=tutorial+asp+net&amp;amp;numOfResults=15" title="http://www.ecubicle.net/gsearch_rss.asmx/GetSearchResults?searchPage=0&amp;amp;gQuery=tutorial+asp+net&amp;amp;numOfResults=15"&gt;http://www.ecubicle.net/gsearch_rss.asmx/GetSearchResults?searchPage=&lt;b&gt;&lt;font color="#990000"&gt;0&lt;/font&gt;&lt;/b&gt;&amp;amp;gQuery=&lt;font color="#990000"&gt;&lt;b&gt;tutorial+asp+net&lt;/b&gt;&lt;/font&gt;&amp;amp;numOfResults=&lt;font color="#990000"&gt;&lt;b&gt;&lt;/b&gt;&lt;/font&gt;&lt;/a&gt;&lt;font color="#990000"&gt;&lt;b&gt;&lt;a&gt;15&lt;/a&gt;&lt;/b&gt;&lt;/font&gt;&lt;/p&gt;&lt;p&gt;In the above, replace the parameter values shown in red with the your query values.&lt;/p&gt;&lt;img src="http://weblogs.com.pk/aggbug.aspx?PostID=136844" width="1" height="1"&gt;</content><author><name>aspnet</name><uri>http://weblogs.com.pk/members/aspnet.aspx</uri></author><category term="asp.net" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/asp.net/default.aspx" /><category term="google maps" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/google+maps/default.aspx" /><category term="linq" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/linq/default.aspx" /><category term="xml" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/xml/default.aspx" /><category term="rss" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/rss/default.aspx" /></entry><entry><title>Extension Methods in VB.NET</title><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/archive/2009/01/06/extension-methods-in-vb-net.aspx" /><id>http://weblogs.com.pk/blogs/aspnet/archive/2009/01/06/extension-methods-in-vb-net.aspx</id><published>2009-01-06T20:48:00Z</published><updated>2009-01-06T20:48:00Z</updated><content type="html">&lt;P&gt;Extension methods allow developers to add functionality to the existing .NET types without recompiling the source, or extending (deriving from the type) the type. For certain types, such as String, these cannot be extended because they are declared as Notinheritable (Sealed). For such scenarios, create an extension method to add custom functionality. Here's an example:&lt;/P&gt;
&lt;DIV&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;Imports&lt;/SPAN&gt;&lt;SPAN&gt; Microsoft.VisualBasic &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;Imports&lt;/SPAN&gt;&lt;SPAN&gt; System.Runtime.CompilerServices &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;Public&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;Module&lt;/SPAN&gt;&lt;SPAN&gt; Module1 &lt;/SPAN&gt;&lt;SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN&gt;Extension()&lt;/SPAN&gt;&lt;SPAN&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN&gt; _ &lt;/SPAN&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;Public&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;Function&lt;/SPAN&gt;&lt;SPAN&gt; ValidateEmailAddress(&lt;/SPAN&gt;&lt;SPAN&gt;ByVal&lt;/SPAN&gt;&lt;SPAN&gt; emailAddress &lt;/SPAN&gt;&lt;SPAN&gt;As&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;String&lt;/SPAN&gt;&lt;SPAN&gt;) &lt;/SPAN&gt;&lt;SPAN&gt;As&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;Boolean&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;Dim&lt;/SPAN&gt;&lt;SPAN&gt; emailRegEx &lt;/SPAN&gt;&lt;SPAN&gt;As&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;New&lt;/SPAN&gt;&lt;SPAN&gt; Regex(&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN&gt;\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN&gt;) &lt;/SPAN&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;If&lt;/SPAN&gt;&lt;SPAN&gt; emailRegEx.IsMatch(emailAddress) &lt;/SPAN&gt;&lt;SPAN&gt;Then&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;Return&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;True&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;Else&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;Return&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;False&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;End&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;If&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;End Function&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;End Module&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;STRONG&gt;The requirements to create an extension method in VB.NET are as follows&lt;/STRONG&gt;:&amp;nbsp; &lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;STRONG&gt;i)&lt;/STRONG&gt; Import &lt;FONT size=3&gt;&lt;STRONG&gt;System.Runtime.CompilerServices&lt;/STRONG&gt;&lt;/FONT&gt; namespace&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;STRONG&gt;ii)&lt;/STRONG&gt; Create a &lt;FONT size=3&gt;&lt;STRONG&gt;Module&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;
&lt;UL&gt;
&lt;LI&gt;Extension methods may &lt;STRONG&gt;only be created in a module&lt;/STRONG&gt;.&amp;nbsp; &lt;BR&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;STRONG&gt;iii)&lt;/STRONG&gt; Use the &lt;FONT size=3&gt;&lt;STRONG&gt;Extension attribute&lt;/STRONG&gt;&lt;/FONT&gt; with the method&lt;/DIV&gt;
&lt;UL&gt;
&lt;LI&gt;Each extension method must have the Extension() attribute&lt;/LI&gt;&lt;/UL&gt;
&lt;DIV&gt;&lt;BR&gt;To use the function defined above, use code like this:&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;BR&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;Dim&lt;/SPAN&gt;&lt;SPAN&gt; s &lt;/SPAN&gt;&lt;SPAN&gt;As&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;String&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;=&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN&gt;rafayali@gmail.com&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;If&lt;/SPAN&gt;&lt;SPAN&gt; s.ValidateEmailAddress() &lt;/SPAN&gt;&lt;SPAN&gt;Then&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;Response.Write(&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN&gt;verified&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN&gt;) &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;Else&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;Response.Write(&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN&gt;check the format of email&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN&gt;) &lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&lt;/SPAN&gt;&lt;FONT face="trebuchet ms,geneva"&gt;&lt;SPAN&gt;End&lt;/SPAN&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;SPAN&gt;If&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/DIV&gt;&lt;img src="http://weblogs.com.pk/aggbug.aspx?PostID=136455" width="1" height="1"&gt;</content><author><name>aspnet</name><uri>http://weblogs.com.pk/members/aspnet.aspx</uri></author><category term="asp.net" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/asp.net/default.aspx" /><category term="regex" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/regex/default.aspx" /><category term="extension method" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/extension+method/default.aspx" /></entry><entry><title>LINQ and ADO .NET Data Services Videos</title><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/archive/2009/01/06/linq-and-ado-net-data-services-videos.aspx" /><id>http://weblogs.com.pk/blogs/aspnet/archive/2009/01/06/linq-and-ado-net-data-services-videos.aspx</id><published>2009-01-06T18:36:00Z</published><updated>2009-01-06T18:36:00Z</updated><content type="html">&lt;P&gt;I have published some tutorials on YouTube on LINQ and ADO .NET Data Services. ADO .NET Data Services allow creation of REST based services which is simply a fancy way of serializing data as XML and returning it over HTTP. You can view these tutorials on my YouTube Channel at &lt;/P&gt;
&lt;P&gt;&lt;A href="http://ca.youtube.com/rafaybinali"&gt;http://ca.youtube.com/rafaybinali&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://weblogs.com.pk/aggbug.aspx?PostID=136449" width="1" height="1"&gt;</content><author><name>aspnet</name><uri>http://weblogs.com.pk/members/aspnet.aspx</uri></author><category term="youtube" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/youtube/default.aspx" /><category term="asp.net" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/asp.net/default.aspx" /><category term="linq" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/linq/default.aspx" /><category term="ado.net data service" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/ado.net+data+service/default.aspx" /></entry><entry><title>Google Maps KML and LINQ to Display Driving Directions</title><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/archive/2009/01/06/google-maps-kml-and-linq-to-display-driving-directions.aspx" /><id>http://weblogs.com.pk/blogs/aspnet/archive/2009/01/06/google-maps-kml-and-linq-to-display-driving-directions.aspx</id><published>2009-01-06T18:21:00Z</published><updated>2009-01-06T18:21:00Z</updated><content type="html">&lt;DIV&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;&lt;FONT color=#000000&gt;The&amp;nbsp;important part is to retrieve the KML file (&lt;STRONG&gt;XML&amp;nbsp;based standard&lt;/STRONG&gt;)&amp;nbsp;from Google Maps (&lt;STRONG&gt;refer to urlString&lt;/STRONG&gt;). Once we have the KML file, we create an&amp;nbsp;XMLDataSource control, retrieve the&amp;nbsp;XmlDocument's&amp;nbsp;InnerXml. After that, we parse the elements to retrieve the directions which are placed in the&amp;nbsp;&amp;lt;name&amp;gt; element under kml/Document/Placemark.&lt;/FONT&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;Dim&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; fromAddress &lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;As&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;String&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; Server.HtmlEncode(txtboxSourceAddress.text) &lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;Dim&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; toAddress &lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;As&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;String&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; Server.HtmlEncode(txtboxDestinationAddress.text) &lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;Dim&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; urlString &lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;As&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;String&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;String&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;.Format(&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;http://maps.google.ca/?q=From {0} to {1}&amp;amp;output=kml&amp;amp;view=text&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;, fromAddress, toAddress) &lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;Dim&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; xmlDataSource2 &lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;As&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;New&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; XmlDataSource() &lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;xmlDataSource2.DataFile &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; urlString &lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;Dim&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; xdoc &lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;As&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; XDocument &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; XDocument.Parse(xmlDataSource2.GetXmlDocument().InnerXml) &lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;Dim&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; ns &lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;As&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; XNamespace &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; XNamespace.Get(&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;http://earth.google.com/kml/2.0&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;) &lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;Dim&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; ele &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; xdoc.Element(ns &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;+&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;kml&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;).Element(ns &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;+&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;Document&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;).Elements(ns &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;+&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;Placemark&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;).Elements(ns &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;+&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;name&lt;/SPAN&gt;&lt;SPAN style="COLOR:#800000;"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;) &lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;GridView1.DataSource &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; ele.Take(ele.Count &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;-&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR:#800080;"&gt;1&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;) &lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;GridView1.DataBind()&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;I have used the XmlDataSource control in this example because this is a code snippet from another project that I worked on. However, we can also use &lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;Dim&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; xdoc &lt;/SPAN&gt;&lt;SPAN style="COLOR:#0000ff;"&gt;As&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; XDocument &lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR:#000000;"&gt; XDocument.Load(urlString)&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;The above line of code would load the KML file from remote server into xdoc. The remaining code remains same from this step onwards.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN style="COLOR:#000000;"&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/DIV&gt;&lt;img src="http://weblogs.com.pk/aggbug.aspx?PostID=136435" width="1" height="1"&gt;</content><author><name>aspnet</name><uri>http://weblogs.com.pk/members/aspnet.aspx</uri></author><category term="asp.net" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/asp.net/default.aspx" /><category term="google maps" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/google+maps/default.aspx" /><category term="linq" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/linq/default.aspx" /></entry><entry><title>YouTube Download Web Service: Integrate YouTube Download into your .NET apps FREE</title><link rel="alternate" type="text/html" href="http://weblogs.com.pk/blogs/aspnet/archive/2009/01/06/youtube-download-web-service-integrate-youtube-download-into-your-net-apps-free.aspx" /><id>http://weblogs.com.pk/blogs/aspnet/archive/2009/01/06/youtube-download-web-service-integrate-youtube-download-into-your-net-apps-free.aspx</id><published>2009-01-06T06:16:00Z</published><updated>2009-01-06T06:16:00Z</updated><content type="html">&lt;P&gt;Here is an interesting web service that allows applications to download youtube videos. Applications that require interaction with youtube can obviously use the YouTube API's to provide exhaustive youtube functionality right from their web sites. However, the only API function that is missed is the ability to download from Youtube.&lt;BR&gt;&lt;BR&gt;The Youtube web service provides this missing functionality.&lt;BR&gt;&lt;BR&gt;The service is located at &lt;A class="" title="YouTube Downloader Web Service" href="http://www.ecubicle.net/youtubedownloader.asmx" target=_blank&gt;http://www.ecubicle.net/youtubedownloader.asmx&lt;/A&gt;&lt;BR&gt;&lt;BR&gt;What the service does is provide the download URL for any video on Youtube. .NET applications can then use any method to access the download URL and download the file. For example, WebClient.DownloadFile() method can be used to download the file directly if the returned URL is passed to DownloadFile.&lt;BR&gt;&lt;BR&gt;Very interesting.&lt;/P&gt;&lt;img src="http://weblogs.com.pk/aggbug.aspx?PostID=136403" width="1" height="1"&gt;</content><author><name>aspnet</name><uri>http://weblogs.com.pk/members/aspnet.aspx</uri></author><category term="youtube" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/youtube/default.aspx" /><category term="download video" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/download+video/default.aspx" /><category term="download youtube" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/download+youtube/default.aspx" /><category term="asp.net" scheme="http://weblogs.com.pk/blogs/aspnet/archive/tags/asp.net/default.aspx" /></entry></feed>