<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.asp.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Sonu Kapoor's WebLog</title><link>http://weblogs.asp.net/sonukapoor/default.aspx</link><description>Application Developer, Writer and much more ...</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Debug Build: 20510.895)</generator><item><title>Moved Blog</title><link>http://weblogs.asp.net/sonukapoor/archive/2005/01/15/353645.aspx</link><pubDate>Sat, 15 Jan 2005 18:34:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:353645</guid><dc:creator>SonuKapoor</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/sonukapoor/rsscomments.aspx?PostID=353645</wfw:commentRss><comments>http://weblogs.asp.net/sonukapoor/archive/2005/01/15/353645.aspx#comments</comments><description>I have finally managed to move my blog to my own website, which I am still building. The blog however is already fully functional. Please update your bookmark to the &lt;a href="http://kapoorsolutions.com/blog/"&gt;new location&lt;/a&gt;. I really appreciate all the experience, which I got from weblogs.asp.net. Thanks so much.&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=353645" width="1" height="1"&gt;</description></item><item><title>Have you heard of Snippet Compiler?</title><link>http://weblogs.asp.net/sonukapoor/archive/2005/01/08/349048.aspx</link><pubDate>Sat, 08 Jan 2005 05:00:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:349048</guid><dc:creator>SonuKapoor</dc:creator><slash:comments>3</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/sonukapoor/rsscomments.aspx?PostID=349048</wfw:commentRss><comments>http://weblogs.asp.net/sonukapoor/archive/2005/01/08/349048.aspx#comments</comments><description>Just saw this cool tool called "&lt;a href="http://www.sliver.com/dotnet/SnippetCompiler/"&gt;Snippet Compiler&lt;/a&gt;" and thought you would be interested in. Always wanted to compile quickly some code snippets without opening Visual Studio .NET and creating a new project? This small and easy to use tool lets you create such snippets with the benefit of having intellisense, compiler errors, warning, tooltips etc. . Here is a screenshot how it looks like:&lt;br /&gt;&lt;br /&gt;&lt;img src="http://www.sliver.com/dotnet/SnippetCompiler/SnippetCompiler.PNG" /&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.sliver.com/dotnet/SnippetCompiler/SnippetCompiler.zip"&gt;Downlod it here.&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Sonu Kapoor&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=349048" width="1" height="1"&gt;</description></item><item><title>Manage TV viewing via XML</title><link>http://weblogs.asp.net/sonukapoor/archive/2005/01/04/346282.aspx</link><pubDate>Tue, 04 Jan 2005 15:25:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:346282</guid><dc:creator>SonuKapoor</dc:creator><slash:comments>5</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/sonukapoor/rsscomments.aspx?PostID=346282</wfw:commentRss><comments>http://weblogs.asp.net/sonukapoor/archive/2005/01/04/346282.aspx#comments</comments><description>Ever heard of viewing&amp;nbsp;TV via XML? &lt;br /&gt;&lt;br /&gt; &lt;blockquote dir="ltr" style="MARGIN-RIGHT: 0px"&gt; &lt;p&gt;&lt;a href="http://membled.com/work/apps/xmltv/"&gt;&lt;em&gt;XMLTV &lt;/em&gt;&lt;/a&gt;&lt;em&gt;is a set of utilities to manage your TV viewing. They work with TV listings stored in the XMLTV format, which is based on XML. The idea is to separate out the backend (getting the listings) from the frontend (displaying them for the user), and to implement useful operations like picking out your favourite programmes as filters that read and write XML documents.&lt;/em&gt; &lt;/p&gt;&lt;/blockquote&gt;Sonu&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=346282" width="1" height="1"&gt;</description></item><item><title>Currency Conversion rates via a Web Service</title><link>http://weblogs.asp.net/sonukapoor/archive/2005/01/03/346002.aspx</link><pubDate>Tue, 04 Jan 2005 00:12:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:346002</guid><dc:creator>SonuKapoor</dc:creator><slash:comments>21</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/sonukapoor/rsscomments.aspx?PostID=346002</wfw:commentRss><comments>http://weblogs.asp.net/sonukapoor/archive/2005/01/03/346002.aspx#comments</comments><description>&lt;p&gt;Some time ago I found the following&amp;nbsp;&lt;a href="http://www.webservicex.net/WS/WSDetails.aspx?CATID=2&amp;amp;WSID=10"&gt;Web Service&lt;/a&gt;, which provides the currency conversion rates for free. The &lt;a href="http://www.webservicex.net/ws/default.aspx"&gt;WebSite&lt;/a&gt; also provides some other very nice services. I thought it would be interesting to bookmark that one. What kind of Web Service do you use to do the currency conversion?&lt;br /&gt;&lt;br /&gt;Sonu&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=346002" width="1" height="1"&gt;</description></item><item><title>Add a JavaScript Confirm function when deleting a row from a datagrid</title><link>http://weblogs.asp.net/sonukapoor/archive/2004/12/29/343685.aspx</link><pubDate>Wed, 29 Dec 2004 15:41:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:343685</guid><dc:creator>SonuKapoor</dc:creator><slash:comments>44</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/sonukapoor/rsscomments.aspx?PostID=343685</wfw:commentRss><comments>http://weblogs.asp.net/sonukapoor/archive/2004/12/29/343685.aspx#comments</comments><description>&lt;p&gt;Lets say your datagrid looks like this:&lt;br /&gt;&lt;br /&gt;&lt;font face="Courier New" color="#a52a2a" size="2"&gt;&amp;lt;asp:datagrid OnItemDataBound="dg1_OnItemDataBound"...&amp;gt;&lt;br /&gt;&amp;lt;Columns&amp;gt;&lt;br /&gt;&amp;nbsp;&amp;lt;asp:TemplateColumn&amp;gt;&lt;br /&gt;&amp;nbsp;&amp;lt;ItemTemplate&amp;gt;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;lt;asp:Button runat="server" Text="Delete" id="btnDelete" CommandName="Delete" CausesValidation="false"&amp;gt;&amp;lt;/asp:Button&amp;gt;&lt;br /&gt;&amp;nbsp;&amp;lt;/ItemTemplate&amp;gt;&lt;br /&gt;&amp;lt;/asp:TemplateColumn&amp;gt;&lt;br /&gt;...&lt;br /&gt;&amp;lt;/asp:datagrid&amp;gt;&lt;/font&gt;&lt;br /&gt;&lt;br /&gt;And in your ItemDataBound of the datagrid you just need to add this:&lt;br /&gt;&lt;br /&gt;&lt;font face="Courier New" color="#a52a2a" size="2"&gt;Sub dg1_OnItemDataBound(ByVal sender As Object, ByVal e As DataGridItemEventArgs)&lt;br /&gt;&amp;nbsp; If e.Item.ItemType = ListItemType.Item Or e.Item.ItemType = ListItemType.AlternatingItem Then&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; CType(e.Item.Cells(0).FindControl("btnDelete"), Button).Attributes.Add("onClick", "return confirm('Are you sure to delete this item?')")&lt;br /&gt;&amp;nbsp;&amp;nbsp;End If&lt;br /&gt;End Sub&lt;br /&gt;&lt;br /&gt;&lt;font face="Times New Roman" color="#000000" size="3"&gt;Sonu&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=343685" width="1" height="1"&gt;</description></item><item><title>&lt;XSLT:Blog /&gt; added TopXML.com to the legend list.</title><link>http://weblogs.asp.net/sonukapoor/archive/2004/12/28/339039.aspx</link><pubDate>Tue, 28 Dec 2004 20:10:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:339039</guid><dc:creator>SonuKapoor</dc:creator><slash:comments>3</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/sonukapoor/rsscomments.aspx?PostID=339039</wfw:commentRss><comments>http://weblogs.asp.net/sonukapoor/archive/2004/12/28/339039.aspx#comments</comments><description>&lt;p&gt;&lt;a href="http://topxml.com/"&gt;TopXML.com&lt;/a&gt; is one of the companies I work for since a while and now they have been added as a &lt;a href="http://www.xsltblog.com/archives/2004/12/xsltblog_welcom_1.html"&gt;legend of the XSLT community&lt;/a&gt; to the &lt;a href="http://www.xsltblog.com/"&gt;&amp;lt;XSLT:Blog /&amp;gt;&lt;/a&gt;. I am sure that I dont need to explain what TopXML.com is about. If you dont know TopXML.com, I recommend that you take a look and you surely will understand why &amp;lt;XSLT:Blog/&amp;gt; added it.&amp;nbsp;A short &amp;lt;snip&amp;gt; of what &amp;lt;XSLT:Blog/&amp;gt;&amp;nbsp;thinks about TopXML.&lt;/p&gt; &lt;blockquote dir="ltr" style="MARGIN-RIGHT: 0px"&gt; &lt;p&gt;"As if I needed any more reasons to make myself look like a fool it seems I forgot to add one *VERY* obvious entry into my last post. To try and avoid any further embarrassment would like to welcome TopXML.com to the "Legends of the XSLT Community" section of this blog. If not obvious please visit TopXML.com and you will quickly understand why TopXML.com should be considered a legend of the XSLT community. TopXML has been promoting the use of XSLT for a very long time providing everything from sample code to complete applications built in XSLT to the development communities abroad."&lt;/p&gt;&lt;/blockquote&gt;Sonu&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=339039" width="1" height="1"&gt;</description></item><item><title>New Design on XMLPitStop</title><link>http://weblogs.asp.net/sonukapoor/archive/2004/12/22/330024.aspx</link><pubDate>Wed, 22 Dec 2004 17:58:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:330024</guid><dc:creator>SonuKapoor</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/sonukapoor/rsscomments.aspx?PostID=330024</wfw:commentRss><comments>http://weblogs.asp.net/sonukapoor/archive/2004/12/22/330024.aspx#comments</comments><description>Just in the case you haven't recognized yet. &lt;a href="http://xmlpitstop.com"&gt;XMLPitStop&lt;/a&gt; has a new design and a cleaner structure. Furthermore we have an admin section which allows us to manage articles and code snippets easily. Feel free to submit your thoughts and ideas to &lt;a href="mailto:headgeek@xmlpitstop.com"&gt;headgeek@xmlpitstop.com&lt;/a&gt; . &lt;br /&gt;&lt;br /&gt;Sonu&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=330024" width="1" height="1"&gt;</description></item><item><title>Cast from type 'DBNull' to type 'String' is not valid.</title><link>http://weblogs.asp.net/sonukapoor/archive/2004/12/21/329284.aspx</link><pubDate>Tue, 21 Dec 2004 23:00:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:329284</guid><dc:creator>SonuKapoor</dc:creator><slash:comments>15</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/sonukapoor/rsscomments.aspx?PostID=329284</wfw:commentRss><comments>http://weblogs.asp.net/sonukapoor/archive/2004/12/21/329284.aspx#comments</comments><description>&lt;p&gt;I have seen this question many times in the ASP.NET forums and thought that it would be a good idea to blog about. &lt;br /&gt;When you are working with functions in the HTML of your DataGrid and passing the value (which can be also NULL) from the database to a function, which accepts a string, then you will get such an error. &lt;br /&gt;&lt;br /&gt;Cast from type 'DBNull' to type 'String' is not valid.&lt;br /&gt;&lt;br /&gt;To get this working you will have to pass the value as an object. That means the function must simply accept it as an object instead of a string. Something like this:&lt;br /&gt;&lt;br /&gt;&lt;font face="Courier New" color="#a52a2a" size="2"&gt;&amp;lt;asp:datagrid id="datagrid".....&amp;gt;&lt;br /&gt;&amp;lt;Columns&amp;gt;&lt;br /&gt;&amp;lt;asp:TemplateColumn ...&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;lt;ItemTemplate&amp;gt;&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;%# DoSomething(Container.DataItem("TheValue")) %&amp;gt;&lt;br /&gt;&amp;nbsp; &amp;lt;/ItemTemplate&amp;gt;&lt;br /&gt;&amp;lt;/asp:TemplateColumn&amp;gt;&lt;br /&gt;&amp;lt;/Columns&amp;gt;&lt;br /&gt;&amp;lt;/asp:datagrid&amp;gt;&lt;br /&gt;&lt;/font&gt;&lt;br /&gt;And in your Codebehind:&lt;br /&gt;&lt;br /&gt;&lt;font face="Courier New" color="#a52a2a" size="2"&gt;function public DoSomething(Dim obj as Object)&lt;br /&gt;&amp;nbsp; If not IsDBNull(obj) then&lt;br /&gt;&amp;nbsp;&amp;nbsp;' Do the processing here...&lt;br /&gt;&amp;nbsp; End If&lt;br /&gt;end function&lt;/font&gt;&lt;br /&gt;&lt;br /&gt;Sonu&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=329284" width="1" height="1"&gt;</description></item><item><title>XML Reblogger passed 1000 posts in nearly one month</title><link>http://weblogs.asp.net/sonukapoor/archive/2004/12/16/317361.aspx</link><pubDate>Thu, 16 Dec 2004 15:19:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:317361</guid><dc:creator>SonuKapoor</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/sonukapoor/rsscomments.aspx?PostID=317361</wfw:commentRss><comments>http://weblogs.asp.net/sonukapoor/archive/2004/12/16/317361.aspx#comments</comments><description>The Reblogger which was published on &lt;A href="http://weblogs.asp.net/sonukapoor/archive/2004/11/11/256040.aspx"&gt;Thursday, November 11, 2004&lt;/a&gt; and started initially with 127 posts has passed today Thurday, 16 December 2004 1000 posts in nearly one month. This is so great. &lt;a href="http://www.topxml.com/reblogger/"&gt;Interested in Reblogger for your own WebSite?&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Sonu&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=317361" width="1" height="1"&gt;</description></item><item><title>XMLPitstop is looking for Authors</title><link>http://weblogs.asp.net/sonukapoor/archive/2004/12/09/279007.aspx</link><pubDate>Thu, 09 Dec 2004 17:29:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:279007</guid><dc:creator>SonuKapoor</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/sonukapoor/rsscomments.aspx?PostID=279007</wfw:commentRss><comments>http://weblogs.asp.net/sonukapoor/archive/2004/12/09/279007.aspx#comments</comments><description>David Silverlight the headgeek of XMLPitStop.com told me that he is looking for authors who want to contribute articles on &lt;a href="http://www.XMLPitStop.com"&gt;www.XMLPitStop.com&lt;/a&gt;. If you have any ideas for an article and would like to publish it on XMLPitStop.com then you can contact either me via the contact page or directly David Silverlight (&lt;a href="mailto:headgeek@xmlpitstop.com"&gt;headgeek@xmlpitstop.com&lt;/a&gt;)&lt;br /&gt;&lt;br /&gt;Sonu&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=279007" width="1" height="1"&gt;</description></item></channel></rss>