<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-5780627948959389492</id><updated>2024-09-10T23:50:17.019+05:30</updated><category term="ASP.Net"/><category term="C#"/><category term=".NET"/><category term="ADO.Net"/><category term="Dell XPS 15z"/><category term="IIS 7"/><category term="Javascript"/><category term="LINQ"/><category term="LINQ to XML"/><category term="SQLSERVER 2005"/><category term="WCF. ASP.Net 4.0"/><category term="Windows 10"/><category term="Windows 7"/><category term="XML"/><title type='text'>Tech World</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>12</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-5780627948959389492.post-5932897848705664795</id><published>2015-08-12T20:04:00.001+05:30</published><updated>2015-08-20T22:23:56.551+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="Dell XPS 15z"/><category scheme="http://www.blogger.com/atom/ns#" term="Windows 10"/><title type='text'>Dell XPS 15z Windows 10 Upgrade</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
Dell hasn&#39;t yet announced support for Windows 10 on Dell XPS 15z laptops. But since I got the upgrade notification, I went ahead and upgraded. First of all, the upgrade wizard complained about Cypress track pad being not a compatible software. And I had to uninstall it. This was the only thing I had to do and the upgrade completed successfully. All existing soft wares including Sql server 2008 R2, 2012, Visual Studio 2012, 2013, 2015, MS Office etc worked perfectly fine. The only thing I missed was the Kaspresky 2015 antivirus, which was supposed to be upgraded before the Windows 10 upgrade. This was fixed by re-installing the antivirus software. Overall, the upgrade was a pretty smooth and a pleasant experience.&amp;nbsp;&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/5932897848705664795/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/5780627948959389492/5932897848705664795' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/5932897848705664795'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/5932897848705664795'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/2015/08/dell-xps-15z-windows-10-upgrade.html' title='Dell XPS 15z Windows 10 Upgrade'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5780627948959389492.post-3117801041073385963</id><published>2012-01-27T12:59:00.000+05:30</published><updated>2012-01-27T12:59:23.465+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="IIS 7"/><category scheme="http://www.blogger.com/atom/ns#" term="WCF. ASP.Net 4.0"/><category scheme="http://www.blogger.com/atom/ns#" term="Windows 7"/><title type='text'>System.TypeLoadException: Could not load type &#39;System.ServiceModel.Activation.HttpModule&#39; from assembly &#39;System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&#39;</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiRUqLMS-QXkOlC8R1pJUTUBBFdo5wITVHM0pvstY0Ff1dpGvas82bFN0641eUlkw_m2PkwZ4qULZs1S_TUHc80zXhNert9FVN9eHzwJkUJrhsKg91KDVT85xAftB0LBYAX_CEoxk7W_zIm/s1600/3.5.1.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;281&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiRUqLMS-QXkOlC8R1pJUTUBBFdo5wITVHM0pvstY0Ff1dpGvas82bFN0641eUlkw_m2PkwZ4qULZs1S_TUHc80zXhNert9FVN9eHzwJkUJrhsKg91KDVT85xAftB0LBYAX_CEoxk7W_zIm/s320/3.5.1.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;System.TypeLoadException: Could not load type &#39;System.ServiceModel.Activation.HttpModule&#39; from assembly &#39;System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&#39;&lt;br /&gt;
&lt;br /&gt;
This started happening after I enabled WCF HTTP and Non-HTTP Activation under Micosoft .NET Framework 3.5.1.&lt;br /&gt;
&lt;br /&gt;
Fix : - run ASP.Net regiis again from 4.0. (Run VS 2010 command prompt and execute aspnet_regiis -i).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/3117801041073385963/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/5780627948959389492/3117801041073385963' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/3117801041073385963'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/3117801041073385963'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/2012/01/systemtypeloadexception-could-not-load.html' title='System.TypeLoadException: Could not load type &#39;System.ServiceModel.Activation.HttpModule&#39; from assembly &#39;System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&#39;'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiRUqLMS-QXkOlC8R1pJUTUBBFdo5wITVHM0pvstY0Ff1dpGvas82bFN0641eUlkw_m2PkwZ4qULZs1S_TUHc80zXhNert9FVN9eHzwJkUJrhsKg91KDVT85xAftB0LBYAX_CEoxk7W_zIm/s72-c/3.5.1.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5780627948959389492.post-388873154792639849</id><published>2009-10-29T22:28:00.002+05:30</published><updated>2010-08-04T15:14:42.599+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="ASP.Net"/><title type='text'>Site Under Maintenance with ASP.Net 2.0</title><content type='html'>&lt;div style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;If you have worked with deploying websites onto production/test environments, you might have wanted to show a &#39;Site Under Maintenance&#39; or a similar message to all those who tries to access the website. To achieve this, people used to resort to all kinds of&amp;nbsp; setups ranging from HttpModules to setting up a html page as default page of the application.&lt;/div&gt;&lt;div style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;Now in Asp.Net 2.0 onwards we have a simple way of acheiving this. Just put a file NAMED&lt;/span&gt; &lt;i&gt;app_offline.htm&lt;/i&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt; in the root folder of the application and : voilà!! all new requests will be redirected to that html page.&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;To revert back, just rename the file to some other name. Neat &amp;amp; clean.&amp;nbsp;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;,Courier,monospace;&quot;&gt;[Edit 04 Aug 2010 ] This might not be good idea as ASP.Net responds with a 404 http code. Ideally it should have been 200.&lt;br /&gt;
&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/388873154792639849/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/5780627948959389492/388873154792639849' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/388873154792639849'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/388873154792639849'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/2009/10/site-under-maintenance-with-aspnet-20.html' title='Site Under Maintenance with ASP.Net 2.0'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5780627948959389492.post-6240241367533291176</id><published>2009-10-12T20:13:00.001+05:30</published><updated>2009-10-12T20:14:02.223+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="C#"/><title type='text'>Simple way to check time consumed by a piece of code using stopwatch class</title><content type='html'>TimeSpan ts;&lt;br /&gt;
string elapsedTime;&lt;br /&gt;
System.Diagnostics.Stopwatch stopWatch = new System.Diagnostics.Stopwatch();&lt;br /&gt;
stopWatch.Start();&lt;br /&gt;
//DO SOME LENGTHY OPERATION&lt;br /&gt;
ts = stopWatch.Elapsed;&lt;br /&gt;
elapsedTime =&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;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; String.Format(&quot;{0:00}:{1:00}:{2:00}.{3:00}&quot;,&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;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ts.Hours, ts.Minutes, ts.Seconds,&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;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ts.Milliseconds / 10);&lt;br /&gt;
&amp;nbsp;stopWatch.Reset();&lt;br /&gt;
&amp;nbsp;stopWatch.Stop();</content><link rel='replies' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/6240241367533291176/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/5780627948959389492/6240241367533291176' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/6240241367533291176'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/6240241367533291176'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/2009/10/simple-way-to-check-time-consumed-by.html' title='Simple way to check time consumed by a piece of code using stopwatch class'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5780627948959389492.post-5163585278349736307</id><published>2009-10-12T19:48:00.004+05:30</published><updated>2009-10-29T22:39:21.465+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="SQLSERVER 2005"/><category scheme="http://www.blogger.com/atom/ns#" term="XML"/><title type='text'>Use XML with SQL</title><content type='html'>Declare @doc xml&lt;br /&gt;
&lt;br /&gt;
set @doc =&#39;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiHiexn98yMFO3Z923thfZIriJLTTNbtccKeXhZTBwHq9VsStedbzutgTuXJKhZP25DrITfPyim1yTksKu46pPVCwpOQaKl9xf9c91HJXdg5NKlt1RW8Tcc59r4rY3pmuGPHOLN3V5jo7xJ/s1600-h/xml.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiHiexn98yMFO3Z923thfZIriJLTTNbtccKeXhZTBwHq9VsStedbzutgTuXJKhZP25DrITfPyim1yTksKu46pPVCwpOQaKl9xf9c91HJXdg5NKlt1RW8Tcc59r4rY3pmuGPHOLN3V5jo7xJ/s320/xml.JPG&quot; /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;/div&gt;&lt;br /&gt;
&#39;&lt;br /&gt;
Declare @handle int&lt;br /&gt;
&lt;br /&gt;
Exec sp_xml_prepareDocument @handle output, @doc&lt;br /&gt;
&lt;br /&gt;
Select ImageName, date From openXML(@handle, N&#39;/r/i&#39;) with (ImageName varchar(20) &#39;n&#39;, date datetime &#39;m&#39;)&lt;br /&gt;
Select ImageName,date From openxml(@handle,&#39;/r/t&#39;) with (ImageName varchar(20) &#39;n&#39;, date datetime &#39;m&#39;)&lt;br /&gt;
&lt;br /&gt;
Exec sp_xml_removeDocument @handle</content><link rel='replies' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/5163585278349736307/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/5780627948959389492/5163585278349736307' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/5163585278349736307'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/5163585278349736307'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/2009/10/use-xml-with-sql.html' title='Use XML with SQL'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiHiexn98yMFO3Z923thfZIriJLTTNbtccKeXhZTBwHq9VsStedbzutgTuXJKhZP25DrITfPyim1yTksKu46pPVCwpOQaKl9xf9c91HJXdg5NKlt1RW8Tcc59r4rY3pmuGPHOLN3V5jo7xJ/s72-c/xml.JPG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5780627948959389492.post-4630348800836400119</id><published>2009-07-23T16:11:00.000+05:30</published><updated>2009-07-23T16:26:28.778+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term=".NET"/><category scheme="http://www.blogger.com/atom/ns#" term="ADO.Net"/><category scheme="http://www.blogger.com/atom/ns#" term="C#"/><title type='text'>Executing a stored procedure with output parameter doesnt return any value.</title><content type='html'>When you use a DataReader object to read data from SqlServer, the parameter passed in as output parameter doesnot get assigned even after excuting the reader.&lt;br /&gt;&lt;br /&gt;Solution:- Close the DataReader and your value will get returned.&lt;br /&gt;&lt;br /&gt;Reason:-  The output parameter is returned at the end of the data stream when you use a DataRader.&lt;br /&gt;&lt;br /&gt;Reference:- http://support.microsoft.com/kb/308621</content><link rel='replies' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/4630348800836400119/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/5780627948959389492/4630348800836400119' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/4630348800836400119'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/4630348800836400119'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/2009/07/executing-stored-procedure-with-output.html' title='Executing a stored procedure with output parameter doesnt return any value.'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5780627948959389492.post-4139177603309634741</id><published>2009-04-08T13:01:00.000+05:30</published><updated>2009-04-08T13:11:20.783+05:30</updated><title type='text'>Sql Server 2005 Linked Server Scripting issue</title><content type='html'>I generated the &#39;CREATE&#39; script of a linked server in my DB and got the following script&lt;br /&gt;&lt;br /&gt;EXEC master.dbo.sp_addlinkedserver @server = N&#39;MYSERVERNAME&#39;,  @provider=N&#39;SQLNCLI&#39;, @datasrc=N&#39;MYINSTANCENAME, @catalog=N&#39;SOMENAME&#39;&lt;br /&gt;&lt;br /&gt;I dropped the same and tried to add it with the above script and it gave me the error&lt;br /&gt;&lt;br /&gt;Msg 15429, Level 16, State 1, Procedure sp_addlinkedserver, Line 42&lt;br /&gt;&#39;(null)&#39; is an invalid product name.&lt;br /&gt;&lt;br /&gt;Solution :- Add the product name also in the sp parameters.&lt;br /&gt;&lt;br /&gt;An sp_helptext on the sp showed this:-&lt;br /&gt;&lt;br /&gt;create procedure sys.sp_addlinkedserver&lt;br /&gt; @server   sysname,    -- server name&lt;br /&gt; @srvproduct  nvarchar(128) = NULL, -- product name (dflt to ss)&lt;br /&gt; @provider  nvarchar(128) = NULL, -- oledb provider name&lt;br /&gt; @datasrc  nvarchar(4000) = NULL, -- oledb datasource property&lt;br /&gt; @location  nvarchar(4000) = NULL, -- oledb location property&lt;br /&gt; @provstr  nvarchar(4000) = NULL, -- oledb provider-string property&lt;br /&gt; @catalog  sysname = NULL   -- oledb catalog property&lt;br /&gt;as&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;etc etc ...&lt;br /&gt;&lt;br /&gt;The Script Linked Server as Create To command somehow missed the @srvproduct parameter.&lt;br /&gt;&lt;br /&gt;So the modified sql statement will be &lt;br /&gt;&lt;br /&gt;EXEC master.dbo.sp_addlinkedserver @server=N&#39;MYSERVERNAME&#39;, @srvproduct=N&#39;MSSQLSERVER&#39;,  @provider=N&#39;SQLNCLI&#39;, @datasrc=N&#39;MYINSTANCENAME, @catalog=N&#39;SOMENAME&#39;</content><link rel='replies' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/4139177603309634741/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/5780627948959389492/4139177603309634741' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/4139177603309634741'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/4139177603309634741'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/2009/04/sql-server-2005-linked-server-scripting.html' title='Sql Server 2005 Linked Server Scripting issue'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5780627948959389492.post-4390022555067805541</id><published>2009-03-04T16:46:00.000+05:30</published><updated>2009-03-04T16:55:20.060+05:30</updated><title type='text'>Regex for matching relative URLs</title><content type='html'>This Regex will match the following Relative URLs&lt;br /&gt;REGEX&lt;br /&gt;-----&lt;br /&gt;^(/[a-zA-Z0-9]+)+(\.[a-zA-Z]{2,4})((\?\w*=?\w*)(\&amp;\w+=\w+)*)?$&lt;br /&gt;&lt;br /&gt;URLs&lt;br /&gt;----&lt;br /&gt;/folder1/page.ax&lt;br /&gt;/folder1/page.php&lt;br /&gt;/folder1/folder2/page.aspx&lt;br /&gt;/folder1/page.aspx?qstring1=value1 (likewise n number of query strings)&lt;br /&gt;&lt;br /&gt;Will not match&lt;br /&gt;&lt;br /&gt;/folder1?/page.aspx   &lt;br /&gt;/folder1/page.aspx?=value1&lt;br /&gt;/folder1/page.aspx?qstring1=value1?qstring2=value2&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;^(/[a-zA-Z0-9]+)+(\.[a-zA-Z]{2,4})((\?\w*=?\w*)(\&amp;\w+=\w+)*)?$</content><link rel='replies' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/4390022555067805541/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/5780627948959389492/4390022555067805541' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/4390022555067805541'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/4390022555067805541'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/2009/03/regex-for-matching-relative-urls.html' title='Regex for matching relative URLs'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5780627948959389492.post-6923873718598636746</id><published>2009-02-27T12:43:00.000+05:30</published><updated>2009-02-27T12:57:50.004+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term=".NET"/><category scheme="http://www.blogger.com/atom/ns#" term="C#"/><category scheme="http://www.blogger.com/atom/ns#" term="LINQ"/><category scheme="http://www.blogger.com/atom/ns#" term="LINQ to XML"/><title type='text'>LINQ ERROR</title><content type='html'>I was working with a LINQ sample and stumbled upon the following error.&lt;br /&gt;&quot;The non-generic type &#39;System.Collections.IEnumerable&#39; cannot be used with type arguments&quot;&lt;br /&gt;&lt;br /&gt;XML file I was using :- &lt;br /&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEji67k1-9r4PVL3CBzHZFX-3_cODyZzhlO41LhGvIt5CIOb5Pd0IUxPr1UiKOjJuAN52Ly6jzmvxYaSqNoqn7x0UjTZ1OR4x72MYlavrgUPtpfK-vHMH889vDV0RcvBMP6eWuekSNLkm1Z0/s1600-h/XML.JPG&quot;&gt;&lt;img style=&quot;float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;width: 271px; height: 320px;&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEji67k1-9r4PVL3CBzHZFX-3_cODyZzhlO41LhGvIt5CIOb5Pd0IUxPr1UiKOjJuAN52Ly6jzmvxYaSqNoqn7x0UjTZ1OR4x72MYlavrgUPtpfK-vHMH889vDV0RcvBMP6eWuekSNLkm1Z0/s320/XML.JPG&quot; border=&quot;0&quot; alt=&quot;&quot;id=&quot;BLOGGER_PHOTO_ID_5307375194447897106&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Code used :-&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;//The application is a ASP.net page &lt;br /&gt;XDocument xDoc = XDocument.Load(HttpContext.Current.Server.MapPath(&quot;Persons.xml&quot;));&lt;br /&gt;&lt;br /&gt;IEnumerable&lt;Person&gt; queryNew = from e in xDoc.Descendants(&quot;Person&quot;)&lt;br /&gt;&lt;br /&gt;                               select new Person{&lt;br /&gt;                                   FirstName = e.Element(&quot;FirstName&quot;).Value,&lt;br /&gt;                                   LastName = e.Element(&quot;LastName&quot;).Value,&lt;br /&gt;                                   Salary = Convert.ToInt32(e.Element(&quot;Salary&quot;).Value)&lt;br /&gt;                               };&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Solution :- IEnumerable is present in both System.Collections.Generic and System.Collections name spaces. The query returns a generic collection. So in this case We should use System.Collections.Generic. So when I provided a &quot;using System.Collections.Generic;&quot; on top of the page, it did the trick for me.</content><link rel='replies' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/6923873718598636746/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/5780627948959389492/6923873718598636746' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/6923873718598636746'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/6923873718598636746'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/2009/02/linq-error.html' title='LINQ ERROR'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEji67k1-9r4PVL3CBzHZFX-3_cODyZzhlO41LhGvIt5CIOb5Pd0IUxPr1UiKOjJuAN52Ly6jzmvxYaSqNoqn7x0UjTZ1OR4x72MYlavrgUPtpfK-vHMH889vDV0RcvBMP6eWuekSNLkm1Z0/s72-c/XML.JPG" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5780627948959389492.post-8126637988928008282</id><published>2008-12-10T12:17:00.001+05:30</published><updated>2008-12-10T12:55:52.600+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="ASP.Net"/><category scheme="http://www.blogger.com/atom/ns#" term="Javascript"/><title type='text'>Check box list validation</title><content type='html'>The following javascript will validate that atleast one checkbox is checked in a checkboxlist . And if a checkbox named &#39;other&#39; is checked , it will check that a textbox that is next to it is not empty .&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;textarea cols=&quot;45&quot; rows=&quot;20&quot;&gt;&lt;br /&gt;&lt;script language=&quot;javascript&quot;&gt;&lt;br /&gt;        function ValidateCheckboxList(){&lt;br /&gt;            try{&lt;br /&gt;                var oCheckBoxList = document.getElementById(&quot;chkbxLstSample&quot;);&lt;br /&gt;                var table = oCheckBoxList.childNodes[0];&lt;br /&gt;                var checkedCount = 0;&lt;br /&gt;                var otherChecked = false;&lt;br /&gt;                for (var i=0;i&lt;table.childnodes.length; td =&quot; table.childNodes[i].childNodes[0];&quot; chekbox =&quot; td.childNodes[0];&quot; label =&quot; td.childNodes[1];&quot; checkedcount =&quot; checkedCount+1;&quot; innertext =&quot;=&quot; otherchecked =&quot; true;&quot;&gt;0)){&lt;br /&gt;                    var oTextBox = document.getElementById(&quot;txtCheck&quot;);&lt;br /&gt;                    if(oTextBox.value == &quot;&quot;){&lt;br /&gt;                        alert(&quot;Enter Text&quot;);&lt;br /&gt;                        oTextBox.focus();&lt;br /&gt;                        return false;&lt;br /&gt;                    }&lt;br /&gt;                  &lt;br /&gt;                 }else if(checkedCount==0){&lt;br /&gt;                        alert(&quot;Check at least one&quot;);&lt;br /&gt;                        return false;&lt;br /&gt;                 }&lt;br /&gt;                  return true;&lt;br /&gt;            }catch(e){&lt;br /&gt;                alert(e.description);&lt;br /&gt;            }&lt;br /&gt;            &lt;br /&gt;        }&lt;br /&gt;    &lt;/script&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;form id=&quot;form1&quot; runat=&quot;server&quot;&gt;&lt;br /&gt;&lt;div&gt;&lt;br /&gt;  &lt;table&gt;&lt;br /&gt;&lt;tbody&gt;&lt;tr&gt;&lt;br /&gt;&lt;td style=&quot;WIDTH: 100px&quot;&gt;&lt;br /&gt;&lt;?xml:namespace prefix = asp /&gt;&lt;asp:checkboxlist id=&quot;chkbxLstSample&quot; runat=&quot;server&quot;&gt;&lt;br /&gt;&lt;asp:listitem&gt;1&lt;/asp:listitem&gt;&lt;br /&gt;&lt;asp:listitem&gt;2&lt;/asp:listitem&gt;&lt;br /&gt;&lt;asp:listitem&gt;3&lt;/asp:listitem&gt;&lt;br /&gt;&lt;asp:listitem&gt;Other&lt;/asp:listitem&gt;&lt;br /&gt;&lt;/asp:checkboxlist&gt;&lt;/td&gt;&lt;br /&gt;&lt;td style=&quot;WIDTH: 100px&quot;&gt;&lt;br /&gt;&lt;asp:button id=&quot;btnTest&quot; runat=&quot;server&quot; text=&quot;Test&quot;&gt;&lt;/asp:button&gt;&lt;br /&gt;&lt;asp:textbox id=&quot;txtCheck&quot; runat=&quot;server&quot;&gt;&lt;/asp:textbox&gt;&lt;/td&gt;&lt;br /&gt;&lt;/tr&gt;&lt;br /&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;/form&gt;&lt;br /&gt;&lt;/textarea&gt;</content><link rel='replies' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/8126637988928008282/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/5780627948959389492/8126637988928008282' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/8126637988928008282'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/8126637988928008282'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/2008/12/check-box-list-validation.html' title='Check box list validation'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5780627948959389492.post-3242883742531436268</id><published>2008-12-10T12:05:00.000+05:30</published><updated>2008-12-10T12:09:30.813+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="ASP.Net"/><title type='text'>How to get the domainname of an ASP.Net application</title><content type='html'>If the application URL is something like &lt;a href=&quot;http://www.mydomain.com/home/homepage.aspx&quot;&gt;www.myDomain.com/home/homepage.aspx&lt;/a&gt; , to get the &lt;a href=&quot;http://www.mydomain.com/&quot;&gt;http://www.mydomain.com/&lt;/a&gt; part from it , we can use the following&lt;br /&gt;(1)HttpContext.Current.Request.Url.Scheme+&quot;://&quot;+ HttpContext.Current.Request.Url.DnsSafeHost&lt;br /&gt;or&lt;br /&gt;(2)HttpContext.Current.Request.Url.Scheme+&quot;://&quot;+ HttpContext.Current.Request.Url.Host</content><link rel='replies' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/3242883742531436268/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/5780627948959389492/3242883742531436268' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/3242883742531436268'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/3242883742531436268'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/2008/12/how-to-get-domainname-of-aspnet.html' title='How to get the domainname of an ASP.Net application'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-5780627948959389492.post-7602991092902563986</id><published>2008-12-09T16:17:00.000+05:30</published><updated>2008-12-10T11:58:44.711+05:30</updated><title type='text'>My first post...</title><content type='html'>As developers we come accross many issues while coding . I was thinking of writing down some of the solutions that I came accross , as blog entries so that it might help others who face the same kind of issues.&lt;br /&gt;Better late than never ;) ..</content><link rel='replies' type='application/atom+xml' href='http://aby-john.blogspot.com/feeds/7602991092902563986/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/5780627948959389492/7602991092902563986' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/7602991092902563986'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/5780627948959389492/posts/default/7602991092902563986'/><link rel='alternate' type='text/html' href='http://aby-john.blogspot.com/2008/12/my-first-post.html' title='My first post...'/><author><name>Aby</name><uri>http://www.blogger.com/profile/00908167037156084122</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='23' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhkQVeiiOLpEvGK0dgieKZPI29D28b7jD1_HiQ9-iIXoNZFkR8Lz0nBPit9doHi3BvR6g2Ol_jV88V4q8Tmid0x0RKYe7RIbh1ReCbXiD1q4J_grEoBlOpK6E-cSZ8WcQ/s220/_MG_6475.JPG'/></author><thr:total>0</thr:total></entry></feed>