<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Mohammed Osman &#187; C#</title>
	<atom:link href="http://osman.it/category/c/feed/" rel="self" type="application/rss+xml" />
	<link>http://osman.it</link>
	<description></description>
	<lastBuildDate>Mon, 05 Dec 2011 20:05:10 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>PLINQO by CodeSmith</title>
		<link>http://osman.it/c/plinqo-by-codesmith/</link>
		<comments>http://osman.it/c/plinqo-by-codesmith/#comments</comments>
		<pubDate>Sat, 16 Jan 2010 23:18:04 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[CodeSmith]]></category>
		<category><![CDATA[PLINQO]]></category>

		<guid isPermaLink="false">http://osman.in/?p=512</guid>
		<description><![CDATA[A lot of people have doubts about whether to use LINQ to SQL for real-world applications, especially since Microsoft has encouraged in favor of the new version of the Entity Framework slated for release with .NET 4.0 and Visual Studio 2010. Recently, I have read the book ASP.NET 3.5 Enterprise Application Development with Visual Studio [...]]]></description>
			<content:encoded><![CDATA[<p>A lot of people have doubts about whether to use LINQ to SQL for real-world applications, especially since Microsoft has encouraged in favor of the new version of the Entity Framework slated for release with .NET 4.0 and Visual Studio 2010.</p>
<p>Recently, I have read the book ASP.NET 3.5 Enterprise Application Development with Visual Studio 2008: Problem Design Solution (Wrox Programmer to Programmer) ~ Vincent Varallo (Author)</p>
<p>This book faithfully follows the very popular Wrox &#8220;Problem &#8211; Design &#8211; Solution&#8221; format, evolving chapter by chapter while analyzing business requirements, examining various design scenarios, and implementing a beginning-to-end solution in a reusable framework. The book uses LINQ to SQL for data access. It covers a lot of important material.</p>
<p>The bottom line is that LINQ to SQL is a perfectly viable alternative when you can guarantee that the database will be Microsoft SQL Server (2000 or later). It has support for POCO (persistence ignorance), stored procedures, lazy loading, and concurrency management, and it works well with SOA (n-tier) architectures.</p>
<p>Do I use LINQ to SQL in new projects?</p>
<p>I Do <img src='http://osman.it/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>Microsoft is not going to stop including LINQ to SQL in the .NET framework until they are convinced EF is a good migration target for all the current LINQ to SQL users. That day has not arrived. Therefore, I believe I have plenty of time to be productive with LINQ to SQL before I must make a change.</p>
<p>The question is, &#8220;Who is adding new features to LINQ to SQL?&#8221; The answer is a product called Plinqo, created by the makers of the code-generation tool, Code Smith. The purpose of Plinqo is to generate LINQ to SQL entities that replace those created when you add a dbml file to a Visual Studio project. In fact, Plinqo will generate the dbml file for you, placing each entity in a separate .cs file under a common folder. Actually, Plinqo creates two files: one for the code-generated entity, and another for your own custom metadata that will not be overwritten by the code-generator (for example, attributes that can drive a dynamic data web site).</p>
<p>While Plinqo generates code that is better organized and easier to read, its power lies in the extensions it provides, such as manager and query classes, a build-in rules engine, audit trail, caching, cloning and detaching entities. It also de-normalizes many-to-many relationships and takes advantage of improvements to the DataContract attributes for .NET 3.5 SP1 (avoiding cyclic references and the need for the &#8220;unidirectional&#8221; serialization option). In addition, Plinqo will create enums instead of entities for tables with lookup values.</p>
<p>But wait, there’s more! Plinqo has actually enabled batch updates and deletes, eliminating possible round-trips when calling SubmitChanges to process updated entities. Wow, now that is something I had been hoping Microsoft would give us in the next version. But thanks to Plinqo, I won’t have to hold my breath waiting for Microsoft, which has stopped adding new features to LINQ to SQL. Lastly, Plinqo also enables batch queries and the ability to process multiple result sets from stored procedures.</p>
<p>And to top it off, Plinqo has templates to create an ADO.NET Data Services layer that exposes entities via a REST-ful web service. There’s even a quick start template that will create both the service and a dynamic data web client in a matter of seconds.</p>
<p>So before you decide to give up on LINQ to SQL, check out Plinqo to get a fresh option for using LINQ to SQL in real-world applications. They’re even offering a free CodeSmith license if you mention Plinqo in a blog or tweet.</p>
<img src="http://osman.it/?ak_action=api_record_view&id=512&type=feed" alt="" /><p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fosman.it%2Fc%2Fplinqo-by-codesmith%2F&amp;title=PLINQO%20by%20CodeSmith" id="wpa2a_2"><img src="http://osman.it/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><hr />
<p><small>© admin for <a href="http://osman.it">Mohammed Osman</a>, 2010. |
<a href="http://osman.it/c/plinqo-by-codesmith/">Permalink</a> |
<a href="http://osman.it/c/plinqo-by-codesmith/#comments">2 comments</a> |
Add to
<a href="http://del.icio.us/post?url=http://osman.it/c/plinqo-by-codesmith/&title=PLINQO by CodeSmith">del.icio.us</a>
<br/>
Post tags: <a href="http://osman.it/tag/codesmith/" rel="tag">CodeSmith</a>, <a href="http://osman.it/tag/plinqo/" rel="tag">PLINQO</a><br/>
</small></p>
<p><small>Feed enhanced by <a href='http://planetozh.com/blog/my-projects/wordpress-plugin-better-feed-rss/'>Better Feed</a> from  <a href='http://planetozh.com/blog/'>Ozh</a></small></p>
]]></content:encoded>
			<wfw:commentRss>http://osman.it/c/plinqo-by-codesmith/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Detect duplicate C# code</title>
		<link>http://osman.it/c/detect-duplicate-c-code/</link>
		<comments>http://osman.it/c/detect-duplicate-c-code/#comments</comments>
		<pubDate>Mon, 26 Jan 2009 16:47:40 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Detect duplicate C# code]]></category>

		<guid isPermaLink="false">http://mdosman.us/?p=344</guid>
		<description><![CDATA[Detect duplicate C# code with Clone Detective for Visual Studio 2008 This is a killer add-in for Visual Studio that detects all that copy &#38; paste coding your coworkers have been doing (&#8216;cause of course you would never do that). Long live the DRY principle! Clone Detective is a Visual Studio integration that allows you [...]]]></description>
			<content:encoded><![CDATA[<p><a target="_blank" href="http://www.codeplex.com/CloneDetectiveVS"><strong>Detect duplicate C# code with Clone Detective for Visual Studio 2008</strong></a></p>
<p>This is a killer add-in for Visual Studio that detects all that copy &amp; paste coding your coworkers have been doing (&lsquo;cause of course you would never do that). Long live the <a target="_blank" href="http://en.wikipedia.org/wiki/Don't_repeat_yourself">DRY</a> principle!</p>
<p>Clone Detective is a Visual Studio integration that allows you to analyze C# projects for source code that is duplicated somewhere else. Having duplicates can easily lead to inconsistencies and often is an indicator for poorly factored code.</p>
<p>For more details please see the <a href="http://www.codeplex.com/CloneDetectiveVS/Wiki/View.aspx?title=Videos&amp;referringTitle=Home"><font color="#3e62a6">Videos</font></a> page.</p>
<p><img alt="ScreenshotSmall.png" src="http://i3.codeplex.com/Project/Download/FileDownload.aspx?ProjectName=CloneDetectiveVS&amp;DownloadId=41494" /></p>
<p>Clone Detective uses <a class="externalLink" href="http://conqat.cs.tum.edu/"><font color="#3e62a6">ConQAT</font></a><font color="#30332d"> to perform the clone detection.</font></p>
<p><img alt="conqat_logo_wide_tum.png" src="http://i3.codeplex.com/Project/Download/FileDownload.aspx?ProjectName=CloneDetectiveVS&amp;DownloadId=40925" /><br />
&nbsp;</p>
<img src="http://osman.it/?ak_action=api_record_view&id=344&type=feed" alt="" /><p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fosman.it%2Fc%2Fdetect-duplicate-c-code%2F&amp;title=Detect%20duplicate%20C%23%20code" id="wpa2a_4"><img src="http://osman.it/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><hr />
<p><small>© admin for <a href="http://osman.it">Mohammed Osman</a>, 2009. |
<a href="http://osman.it/c/detect-duplicate-c-code/">Permalink</a> |
<a href="http://osman.it/c/detect-duplicate-c-code/#comments">No comment</a> |
Add to
<a href="http://del.icio.us/post?url=http://osman.it/c/detect-duplicate-c-code/&title=Detect duplicate C# code">del.icio.us</a>
<br/>
Post tags: <a href="http://osman.it/tag/detect-duplicate-c-code/" rel="tag">Detect duplicate C# code</a><br/>
</small></p>
<p><small>Feed enhanced by <a href='http://planetozh.com/blog/my-projects/wordpress-plugin-better-feed-rss/'>Better Feed</a> from  <a href='http://planetozh.com/blog/'>Ozh</a></small></p>
]]></content:encoded>
			<wfw:commentRss>http://osman.it/c/detect-duplicate-c-code/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>String Basics in .NET</title>
		<link>http://osman.it/c/string-basics-in-net/</link>
		<comments>http://osman.it/c/string-basics-in-net/#comments</comments>
		<pubDate>Tue, 30 Dec 2008 22:15:37 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Basics]]></category>
		<category><![CDATA[String]]></category>

		<guid isPermaLink="false">http://mdosman.us/?p=249</guid>
		<description><![CDATA[I&#8217;ve used the snippet of code at the end of this article twice in the last week to clear up some misunderstandings about strings in .NET. System.String is a reference type in .NET. Don&#8217;t let anyone mislead you into thinking otherwise. You&#8217;ll hear people saying strings &#8220;act like value types&#8221;, but this doesn&#8217;t mean the [...]]]></description>
			<content:encoded><![CDATA[<p>I&rsquo;ve used the snippet of code at the end of this article twice in the last week to clear up some misunderstandings about strings in .NET.</p>
<p>System.String is a reference type in .NET. Don&rsquo;t let anyone mislead you into thinking otherwise. You&rsquo;ll hear people saying strings &ldquo;act like value types&rdquo;, but this doesn&rsquo;t mean the runtime makes a copy of the string during assignment operations, and it doesn&rsquo;t make a copy of a string when passing the string as a parameter.</p>
<p>The equality operator and String.Equals method compare the <i>values</i> of two string objects, and you won&rsquo;t find a property or method on System.String with the ability to modify the contents of a string &ndash; only return a new string object. Because of these two behaviors we sometimes say strings have value type semantics (they <i>feel</i> like value types), but strings are reference types in the runtime. An assignment operation does not copy a string, but assigns a reference. The value given to a string parameter in a method call is the reference, not a copy of the string&rsquo;s value.</p>
<p>&nbsp;</p>
<div style="border-right: windowtext 1pt solid; padding-right: 0pt; border-top: windowtext 1pt solid; padding-left: 0pt; font-size: 8pt; background: #ffffcc; padding-bottom: 0pt; border-left: windowtext 1pt solid; color: #000000; padding-top: 0pt; border-bottom: windowtext 1pt solid; font-family: Lucida Sans Typewriter Regular">
<p style="margin: 0px"><span style="background: #ffffcc; color: #0000ff">using</span><span style="background: #ffffcc"> System;</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #0000ff">class</span><span style="background: #ffffcc"> Class1</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">{ </span></p>
<p style="margin: 0px"><span style="background: #ffffcc">[STAThread]</span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #0000ff">static</span><span style="background: #ffffcc"> </span><span style="background: #ffffcc; color: #0000ff">void</span><span style="background: #ffffcc"> Main(</span><span style="background: #ffffcc; color: #0000ff">string</span><span style="background: #ffffcc">[] args)</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">{ </span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #0000ff">string</span><span style="background: #ffffcc"> s1 = &quot;Hello&quot;;</span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #0000ff">string</span><span style="background: #ffffcc"> s2 = s1;</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// this test will compare the values of the strings</span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// result will be TRUE since both s1 and s2 </span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// refer to a string with the value &quot;Hello&quot; </span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #0000ff">bool</span><span style="background: #ffffcc"> result = String.Equals(s1, s2);</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">Console.WriteLine(&quot;String.Equals(s1, s2) = {0}&quot;, result);</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// next we will check identity</span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// ReferenceEquals will return true if both parameters </span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// point to the same object</span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// result will be TRUE -both s1 and s2reference </span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// the same object.</span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// strings are reference types</span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// there is no copy made on assignment (s2 = s1)</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">result = Object.ReferenceEquals(s1, s2);</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">Console.WriteLine(&quot;Object.ReferenceEquals(s1, s2) = {0}&quot;, result);</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// now we will make a copy of the string</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">s2 = String.Copy(s1);</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// compare string values again</span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// result will be TRUE &#8211; both s1 and s2 </span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// refer tostrings with the value of &quot;Hello&quot;</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">result = String.Equals(s1, s2);</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">Console.WriteLine(&quot;String.Equals(s1, s2) = {0}&quot;, result);</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// check identity again</span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// result will be FALSE</span></p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #008000">// s1 and s2 point to different object instancesbecause we forced a copy</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">result = Object.ReferenceEquals(s1, s2);</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">Console.WriteLine(&quot;Object.ReferenceEquals(s1, s2) = {0}&quot;, result); </span></p>
<p style="margin: 0px"><span style="background: #ffffcc">}</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">}</span></p>
</div>
<p>The sample code in this post demonstrates that the run time maintains a string intern pool. The intern pool allows sharing of string instances. Interning is primarily a memory optimization, but can also be a <a href="http://blogs.msdn.com/cbrumme/archive/2003/04/22/51371.aspx">performance optimization</a> in some unique scenarios.</p>
<p>The runtime&nbsp;will store&nbsp;strings literals in the intern pool. For example:</p>
<p>&nbsp;</p>
<div style="border-right: windowtext 1pt solid; padding-right: 0pt; border-top: windowtext 1pt solid; padding-left: 0pt; font-size: 8pt; background: #ffffcc; padding-bottom: 0pt; border-left: windowtext 1pt solid; color: #000000; padding-top: 0pt; border-bottom: windowtext 1pt solid; font-family: Lucida Sans Typewriter Regular">
<p style="margin: 0px"><span style="background: #ffffcc; color: #0000ff">using</span><span style="background: #ffffcc"> System;</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #0000ff">class</span><span style="background: #ffffcc"> Class1</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">{</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; [STAThread]</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #0000ff">static</span><span style="background: #ffffcc"> </span><span style="background: #ffffcc; color: #0000ff">void</span><span style="background: #ffffcc"> Main(</span><span style="background: #ffffcc; color: #0000ff">string</span><span style="background: #ffffcc">[] args)</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; {</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #0000ff">string</span><span style="background: #ffffcc"> s1 = &quot;bbb&quot;;</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #0000ff">string</span><span style="background: #ffffcc"> s2 = &quot;bbb&quot;;</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; Console.WriteLine(&quot;{0},{1}&quot;, s1, s2);</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; }</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">}</span></p>
</div>
<p>&nbsp;</p>
<p>If you look at the IL code for the above program, you might be tempted to think we are dealing with two different string instances. In other words, s1 and s2 will point to different string objects.</p>
<p>&nbsp;</p>
<div style="border-right: windowtext 1pt solid; padding-right: 0pt; border-top: windowtext 1pt solid; padding-left: 0pt; font-size: 8pt; background: #ffffcc; padding-bottom: 0pt; border-left: windowtext 1pt solid; color: #000000; padding-top: 0pt; border-bottom: windowtext 1pt solid; font-family: Lucida Sans Typewriter Regular">
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp; IL_0000:&nbsp; ldstr&nbsp;&nbsp;&nbsp; &nbsp; &quot;bbb&quot;</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp; IL_0005:&nbsp; stloc.0</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp; IL_0006:&nbsp; ldstr&nbsp;&nbsp;&nbsp; &nbsp; &quot;bbb&quot;</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp; IL_000b:&nbsp; stloc.1</span></p>
</div>
<p>&nbsp;</p>
<p>This is not the case, as the following program will demonstrate.</p>
<p>&nbsp;</p>
<div style="border-right: windowtext 1pt solid; padding-right: 0pt; border-top: windowtext 1pt solid; padding-left: 0pt; font-size: 8pt; background: #ffffcc; padding-bottom: 0pt; border-left: windowtext 1pt solid; color: #000000; padding-top: 0pt; border-bottom: windowtext 1pt solid; font-family: Lucida Sans Typewriter Regular">
<p style="margin: 0px"><span style="background: #ffffcc; color: #0000ff">using</span><span style="background: #ffffcc"> System;</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc; color: #0000ff">class</span><span style="background: #ffffcc"> Class1</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">{&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; [STAThread]</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #0000ff">static</span><span style="background: #ffffcc"> </span><span style="background: #ffffcc; color: #0000ff">void</span><span style="background: #ffffcc"> Main(</span><span style="background: #ffffcc; color: #0000ff">string</span><span style="background: #ffffcc">[] args)</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; {&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp; </span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #0000ff">string</span><span style="background: #ffffcc"> s1 = &quot;bbbbbb&quot;;</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #0000ff">string</span><span style="background: #ffffcc"> s2 = &quot;bbbbbb&quot;;</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// this expression returns true</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// both string variables reference the </span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// same interned string</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #0000ff">bool</span><span style="background: #ffffcc"> b = Object.ReferenceEquals(s1, s2);</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; Console.WriteLine(b);</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// create a new string with the same value</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// as the above: &quot;bbbbbb&quot;</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #0000ff">string</span><span style="background: #ffffcc"> s3 = </span><span style="background: #ffffcc; color: #0000ff">new</span><span style="background: #ffffcc"> </span><span style="background: #ffffcc; color: #0000ff">string</span><span style="background: #ffffcc">(&#8216;b&#8217;, 6);</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// this expression returns false</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// even though s3 references &quot;bbbbbb&quot;, </span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// it&#8217;s not the same string instance </span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// referenced by s1,s2</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; b = Object.ReferenceEquals(s1, s3);</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; Console.WriteLine(b);</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// See if &quot;bbbbbb&quot; is already interned by</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// checking the reference returned by Intern</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #0000ff">string</span><span style="background: #ffffcc"> s4 = String.Intern(s3);</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// this expression returns true</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; </span><span style="background: #ffffcc; color: #008000">// s4 is pointing to the same object as s1,s2</span></p>
<p style="margin: 0px">&nbsp;</p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; b = Object.ReferenceEquals(s1, s4);</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; Console.WriteLine(b);</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">&nbsp;&nbsp;&nbsp; }</span></p>
<p style="margin: 0px"><span style="background: #ffffcc">}</span></p>
</div>
<p>&nbsp;</p>
<img src="http://osman.it/?ak_action=api_record_view&id=249&type=feed" alt="" /><p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fosman.it%2Fc%2Fstring-basics-in-net%2F&amp;title=String%20Basics%20in%20.NET" id="wpa2a_6"><img src="http://osman.it/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><hr />
<p><small>© admin for <a href="http://osman.it">Mohammed Osman</a>, 2008. |
<a href="http://osman.it/c/string-basics-in-net/">Permalink</a> |
<a href="http://osman.it/c/string-basics-in-net/#comments">No comment</a> |
Add to
<a href="http://del.icio.us/post?url=http://osman.it/c/string-basics-in-net/&title=String Basics in .NET">del.icio.us</a>
<br/>
Post tags: <a href="http://osman.it/tag/basics/" rel="tag">Basics</a>, <a href="http://osman.it/tag/string/" rel="tag">String</a><br/>
</small></p>
<p><small>Feed enhanced by <a href='http://planetozh.com/blog/my-projects/wordpress-plugin-better-feed-rss/'>Better Feed</a> from  <a href='http://planetozh.com/blog/'>Ozh</a></small></p>
]]></content:encoded>
			<wfw:commentRss>http://osman.it/c/string-basics-in-net/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Extract links &amp; Automate download using C# AutoIt</title>
		<link>http://osman.it/c/extract-links-using-c/</link>
		<comments>http://osman.it/c/extract-links-using-c/#comments</comments>
		<pubDate>Sat, 27 Dec 2008 23:40:53 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Extract links C# AutoIt]]></category>

		<guid isPermaLink="false">http://mdosman.us/?p=234</guid>
		<description><![CDATA[I&#8217;m sure you all are aware of rapidshare. Most of the time these downloads links are spread across the website which makes it very difficult to get them.&#160; So, Instead of wasting time in downloading each link at a time, why not extract these links and store in some file ( may be text file [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m sure you all are aware of rapidshare. Most of the time these downloads links are spread across the website which makes it very difficult to get them.&nbsp; So, Instead of wasting time in downloading each link at a time, why not extract these links and store in some file ( may be text file ) and then use some script to do this dirty work.</p>
<p>Here is the C# code to extract from any url</p>
<hr />
<p>&nbsp;</p>
<pre class="coloredcode">
HttpWebRequest request;
HttpWebResponse response;
Stream s;
<span class="kwd">string</span> strPath = Application.StartupPath + @<span class="st">&quot;\Extract.txt&quot;</span>;
TextWriter tsw = <span class="kwd">new</span> StreamWriter(strPath, <span class="kwd">true</span>);
List&lt;<span class="kwd">string</span>&gt; lst = <span class="kwd">new</span> List&lt;<span class="kwd">string</span>&gt;();
<span class="cmt">// create a request to the url </span>
request = (HttpWebRequest)WebRequest.Create(<span class="st">&quot;http://somewebsite.com&quot;</span>);
<span class="cmt">// get the response </span>
response = (HttpWebResponse)request.GetResponse();
<span class="cmt">// get the stream of data and read into a string </span>
s = response.GetResponseStream();
<span class="kwd">string</span> strContents = <span class="kwd">new</span> StreamReader(s).ReadToEnd();
Regex r = <span class="kwd">new</span>
    Regex(<span class="st">&quot;href\\s*=\\s*(?:(?:\\\&quot;</span>(?&lt;<span class="gen">url&gt;[^\\\<span class="st">&quot;]*)\\\&quot;</span>)|(?&gt;[^\\s]* ))<span class="st">&quot;);
MatchCollection mc1 = r.Matches(strContents);
foreach (Match m1 in mc1)
{
    Group grp = m1.Groups[1];
    string strRSLink = grp.Value;
    strRSLink =
    Regex.Replace(strRSLink, @&quot;</span>(.*)(\.)(html)$<span class="st">&quot;, &quot;</span>$1<span class="st">&quot;, RegexOptions.IgnoreCase);
    if (Regex.IsMatch(strRSLink, @&quot;</span>http://rapidshare.com&quot;, RegexOptions.IgnoreCase))
    {
        <span class="kwd">if</span> (!lst.Exists(i =&gt; i.Equals(strRSLink)))
            lst.Add(strRSLink);
    }
}
<span class="kwd">foreach</span> (var item <span class="kwd">in</span> lst)
{
    tsw.WriteLine(item);
}
tsw.Close();

</span>
</pre>
<p>And then you can use&nbsp;AutoIt scripting language to automate the download using any download manager. I&#8217;m&nbsp;using Internet download manager which is one of&nbsp;the best donwload manager&nbsp;tool.</p>
<p><a href="http://www.autoitscript.com/autoit3/downloads.shtml">AutoIt</a> (and AutoItX) v3.3.0.0 released (24th December, 2008).AutoIt v3 is a freeware BASIC-like scripting language designed for automating the Windows GUI and general scripting. It uses a combination of simulated keystrokes, mouse movement and window/control manipulation in order to automate tasks in a way not possible or reliable with other languages (e.g. VBScript and SendKeys). AutoIt is also very small, self-contained and will run on all versions of Windows out-of-the-box with no annoying &quot;runtimes&quot; required!&nbsp;.</p>
<p>Just install it and use the following&nbsp;AutoIt script&nbsp;to automate the download.&nbsp;Here is the code</p>
<hr />
<p>&nbsp;</p>
<pre class="coloredcode">
Local $program = @ProgramFilesDir &amp; <span class="st">'\Internet Download Manager\IDMan.exe'</span>
Local $file = @DesktopDir &amp; <span class="st">'\Autoit\RapidLinks.txt'</span>
Local $h_file
Local $url
Local $cnt = 0

        $h_file = FileOpen($file, 0)
        If $h_file = -1 Then
                SetError(1)
        EndIf

        Run($program)
        While 1
                $url = FileReadLine($h_file)
                If @error = -1 Then ExitLoop

                If $cnt = 2 Then
                        Sleep(240000)
                        $cnt = 0
                EndIf

                ;MsgBox(0,<span class="st">&quot;URL&quot;</span>,$url)
                WinWait(<span class="st">&quot;Internet Download Manager 5.15&quot;</span>)

                If Not WinActive(<span class="st">&quot;Internet Download Manager 5.15&quot;</span>) Then _
                        WinActivate(<span class="st">&quot;Internet Download Manager 5.15&quot;</span>)

                WinWaitActive(<span class="st">&quot;Internet Download Manager 5.15&quot;</span>)
                Send(<span class="st">&quot;!ta&quot;</span>)

                WinWait(<span class="st">&quot;Enter new address to download&quot;</span>)

                If Not WinActive(<span class="st">&quot;Enter new address to download&quot;</span>) Then _
                        WinActivate(<span class="st">&quot;Enter new address to download&quot;</span>)

                WinWaitActive(<span class="st">&quot;Enter new address to download&quot;</span>)
                Send($url)
                Send(<span class="st">&quot;!k&quot;</span>)

                WinWait(<span class="st">&quot;Download File Info&quot;</span>)

                If Not WinActive(<span class="st">&quot;Download File Info&quot;</span>) Then _
                        WinActivate(<span class="st">&quot;Download File Info&quot;</span>)

                WinWaitActive(<span class="st">&quot;Download File Info&quot;</span>)
                Send(<span class="st">&quot;!s&quot;</span>)
                $cnt += 1
                Sleep(5000)

        WEnd

        FileClose($h_file)
</pre>
<img src="http://osman.it/?ak_action=api_record_view&id=234&type=feed" alt="" /><p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fosman.it%2Fc%2Fextract-links-using-c%2F&amp;title=Extract%20links%20%26%23038%3B%20Automate%20download%20using%20C%23%20AutoIt" id="wpa2a_8"><img src="http://osman.it/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><hr />
<p><small>© admin for <a href="http://osman.it">Mohammed Osman</a>, 2008. |
<a href="http://osman.it/c/extract-links-using-c/">Permalink</a> |
<a href="http://osman.it/c/extract-links-using-c/#comments">One comment</a> |
Add to
<a href="http://del.icio.us/post?url=http://osman.it/c/extract-links-using-c/&title=Extract links &#038; Automate download using C# AutoIt">del.icio.us</a>
<br/>
Post tags: <a href="http://osman.it/tag/extract-links-c-autoit/" rel="tag">Extract links C# AutoIt</a><br/>
</small></p>
<p><small>Feed enhanced by <a href='http://planetozh.com/blog/my-projects/wordpress-plugin-better-feed-rss/'>Better Feed</a> from  <a href='http://planetozh.com/blog/'>Ozh</a></small></p>
]]></content:encoded>
			<wfw:commentRss>http://osman.it/c/extract-links-using-c/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to get return value from stored procedure ?</title>
		<link>http://osman.it/c/how-to-get-return-value-from-stored-procedure/</link>
		<comments>http://osman.it/c/how-to-get-return-value-from-stored-procedure/#comments</comments>
		<pubDate>Wed, 24 Dec 2008 23:56:35 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[return value from stored procedure]]></category>

		<guid isPermaLink="false">http://mdosman.us/?p=222</guid>
		<description><![CDATA[Recently one of my friend asked me to review his code to&#160;see why he was not able to get the return value from stored procedure. With the stored procedure,&#160;he was&#160;returning&#160;1&#160;in the stored procedure if the operation doesn&#8217;t succeed.&#160;He&#160;was executing the command via IDBCommand.ExecuteNonQuery() and then check the return value to see how many records were [...]]]></description>
			<content:encoded><![CDATA[<p><span class="Apple-style-span" style="word-spacing: 0px; font: 12px Arial; text-transform: none; color: rgb(64,64,64); text-indent: 0px; letter-spacing: normal; border-collapse: separate; orphans: 2; widows: 2; webkit-border-horizontal-spacing: 0px; webkit-border-vertical-spacing: 0px; webkit-text-decorations-in-effect: none; webkit-text-size-adjust: auto; webkit-text-stroke-width: 0">Recently one of my friend asked me to review his code to&nbsp;see why he was not able to get the return value from stored procedure. </span></p>
<p><span class="Apple-style-span" style="word-spacing: 0px; font: 12px Arial; text-transform: none; color: rgb(64,64,64); text-indent: 0px; letter-spacing: normal; border-collapse: separate; orphans: 2; widows: 2; webkit-border-horizontal-spacing: 0px; webkit-border-vertical-spacing: 0px; webkit-text-decorations-in-effect: none; webkit-text-size-adjust: auto; webkit-text-stroke-width: 0">With the stored procedure,&nbsp;he was&nbsp;returning&nbsp;1&nbsp;in the stored procedure if the operation doesn&#8217;t succeed.&nbsp;He&nbsp;was executing the command via <a href="http://msdn.microsoft.com/en-us/library/system.data.idbcommand.executenonquery.aspx">IDBCommand.ExecuteNonQuery()</a> and then check the return value to see how many records were affected.&nbsp; Apparently ExecuteNonQuery only returns the number of affected rows on SELECT, INSERT and DELETE statements; for everything else it returns -1.&nbsp; So, here is what&nbsp;I suggested him to&nbsp;get a return value from a stored procedure.</span></p>
<p>&nbsp;</p>
<dd class="Text">
<p><span class="Apple-style-span" style="word-spacing: 0px; font: 12px Arial; text-transform: none; color: rgb(64,64,64); text-indent: 0px; letter-spacing: normal; border-collapse: separate; orphans: 2; widows: 2; webkit-border-horizontal-spacing: 0px; webkit-border-vertical-spacing: 0px; webkit-text-decorations-in-effect: none; webkit-text-size-adjust: auto; webkit-text-stroke-width: 0">Let&#8217;s assume a simplistic stored procedure as follows:</span></p>
<p><span class="Apple-style-span" style="word-spacing: 0px; font: 12px Arial; text-transform: none; color: rgb(64,64,64); text-indent: 0px; letter-spacing: normal; border-collapse: separate; orphans: 2; widows: 2; webkit-border-horizontal-spacing: 0px; webkit-border-vertical-spacing: 0px; webkit-text-decorations-in-effect: none; webkit-text-size-adjust: auto; webkit-text-stroke-width: 0"></p>
<table cellspacing="1" cellpadding="1" width="200" summary="" border="1">
<tbody>
<tr>
<td>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt; color: blue">ALTER</span><span style="font-size: 10pt"> <span style="color: blue">PROC</span> usp_TestReturnOnly</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt; color: blue">AS</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt; color: blue">BEGIN</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: blue">RETURN</span> 1</span></div>
<p>            <span style="font-size: 10pt; color: blue">END</span></td>
</tr>
</tbody>
</table>
<p></span></p>
<p><span class="Apple-style-span" style="word-spacing: 0px; font: 12px Arial; text-transform: none; color: rgb(64,64,64); text-indent: 0px; letter-spacing: normal; border-collapse: separate; orphans: 2; widows: 2; webkit-border-horizontal-spacing: 0px; webkit-border-vertical-spacing: 0px; webkit-text-decorations-in-effect: none; webkit-text-size-adjust: auto; webkit-text-stroke-width: 0"></p>
<p>You can&#8217;t use ExecuteScalar to get the returned value, and ExecuteNonQuery will always return -1.&nbsp; To get the value back, you need to add a return value parameter to the command.&nbsp; The name of the parameter is&nbsp;not important.&nbsp; The C# data access code to get the value returned by that procedure will be as follows:</p>
<table cellspacing="1" cellpadding="1" width="622" summary="" border="1" style="width: 622px; height: 23px">
<tbody>
<tr>
<td>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt; color: blue">private</span><span style="font-size: 10pt"> <span style="color: blue">int</span> ExecuteStoredProcedure(<span style="color: blue">string</span> strStoredProcedureName)</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">{</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp; <span style="color: #2b91af">SqlConnection</span> sCon= <span style="color: blue">new</span> <span style="color: #2b91af">SqlConnection</span>(strConnectionString);</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal">&nbsp;</div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp; <span style="color: green">// Command &#8211; specify as StoredProcedure</span></span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp; <span style="color: #2b91af">SqlCommand</span> sCmd= <span style="color: blue">new</span> <span style="color: #2b91af">SqlCommand</span>(strStoredProcedureName, sCon);</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp; sCmd.CommandType = <span style="color: #2b91af">CommandType</span>.StoredProcedure;</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal">&nbsp;</div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp; <span style="color: green">// Return value as parameter</span></span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp; <span style="color: #2b91af">SqlParameter</span> spReturnValue = <span style="color: blue">new</span> <span style="color: #2b91af">SqlParameter</span>(<span style="color: #a31515">&quot;returnValue&quot;</span>, <span style="color: #2b91af">SqlDbType</span>.Int);</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp; spReturnValue .Direction = <span style="color: #2b91af">ParameterDirection</span>.ReturnValue;</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp; sCmd.Parameters.Add(spReturnValue );</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal">&nbsp;</div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="color: green">&nbsp;&nbsp;&nbsp; // Execute the stored procedure</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp; sCon.Open();</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp; sCmd.ExecuteNonQuery();</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp; sCon.Close();</span></div>
<div style="margin: 0in 0in 0pt; line-height: normal">&nbsp;</div>
<div style="margin: 0in 0in 0pt; line-height: normal"><span style="font-size: 10pt">&nbsp;&nbsp; <span style="color: blue">return</span> <span style="color: #2b91af">Convert</span>.ToInt32(spReturnValue .Value);</span></div>
<div style="margin: 0in 0in 10pt"><span style="font-size: 10pt; line-height: 115%">}</span></div>
</td>
</tr>
</tbody>
</table>
<p>&nbsp;</p>
<p></span></p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
</dd>
<img src="http://osman.it/?ak_action=api_record_view&id=222&type=feed" alt="" /><p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fosman.it%2Fc%2Fhow-to-get-return-value-from-stored-procedure%2F&amp;title=How%20to%20get%20return%20value%20from%20stored%20procedure%20%3F" id="wpa2a_10"><img src="http://osman.it/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><hr />
<p><small>© admin for <a href="http://osman.it">Mohammed Osman</a>, 2008. |
<a href="http://osman.it/c/how-to-get-return-value-from-stored-procedure/">Permalink</a> |
<a href="http://osman.it/c/how-to-get-return-value-from-stored-procedure/#comments">No comment</a> |
Add to
<a href="http://del.icio.us/post?url=http://osman.it/c/how-to-get-return-value-from-stored-procedure/&title=How to get return value from stored procedure ?">del.icio.us</a>
<br/>
Post tags: <a href="http://osman.it/tag/return-value-from-stored-procedure/" rel="tag">return value from stored procedure</a><br/>
</small></p>
<p><small>Feed enhanced by <a href='http://planetozh.com/blog/my-projects/wordpress-plugin-better-feed-rss/'>Better Feed</a> from  <a href='http://planetozh.com/blog/'>Ozh</a></small></p>
]]></content:encoded>
			<wfw:commentRss>http://osman.it/c/how-to-get-return-value-from-stored-procedure/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Free C# and VB Coding Standards</title>
		<link>http://osman.it/c/free-c-and-vb-coding-standards-reference-documents/</link>
		<comments>http://osman.it/c/free-c-and-vb-coding-standards-reference-documents/#comments</comments>
		<pubDate>Tue, 23 Dec 2008 21:03:07 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Coding]]></category>
		<category><![CDATA[Standards]]></category>

		<guid isPermaLink="false">http://mdosman.us/?p=206</guid>
		<description><![CDATA[Clint Edmonson has gifted us for the holidays with free coding standards documents for C# and VB. I totally agree when he said &#8220;It doesn&#8217;t matter what the standards are, as long as you have them and everyone agrees to adhere to them!&#8221;  [ GET THEM HERE ] © admin for Mohammed Osman, 2008. &#124; [...]]]></description>
			<content:encoded><![CDATA[<p>Clint Edmonson has gifted us for the holidays with free coding standards documents for C# and VB.</p>
<p>I totally agree when he said</p>
<p>&#8220;It doesn&#8217;t matter what the standards are, as long as you have them and everyone agrees to adhere to them!&#8221; </p>
<p>[ <a href="http://www.notsotrivial.net/blog/post/2008/12/Holiday-Goodie-Bag-Free-C-and-VB-Coding-Standards-Reference-Documents.aspx" target="_blank"><span style="color: #000099;">GET THEM HERE</span></a> ]</p>
<img src="http://osman.it/?ak_action=api_record_view&id=206&type=feed" alt="" /><p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fosman.it%2Fc%2Ffree-c-and-vb-coding-standards-reference-documents%2F&amp;title=Free%20C%23%20and%20VB%20Coding%20Standards" id="wpa2a_12"><img src="http://osman.it/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><hr />
<p><small>© admin for <a href="http://osman.it">Mohammed Osman</a>, 2008. |
<a href="http://osman.it/c/free-c-and-vb-coding-standards-reference-documents/">Permalink</a> |
<a href="http://osman.it/c/free-c-and-vb-coding-standards-reference-documents/#comments">4 comments</a> |
Add to
<a href="http://del.icio.us/post?url=http://osman.it/c/free-c-and-vb-coding-standards-reference-documents/&title=Free C# and VB Coding Standards">del.icio.us</a>
<br/>
Post tags: <a href="http://osman.it/tag/coding/" rel="tag">Coding</a>, <a href="http://osman.it/tag/standards/" rel="tag">Standards</a><br/>
</small></p>
<p><small>Feed enhanced by <a href='http://planetozh.com/blog/my-projects/wordpress-plugin-better-feed-rss/'>Better Feed</a> from  <a href='http://planetozh.com/blog/'>Ozh</a></small></p>
]]></content:encoded>
			<wfw:commentRss>http://osman.it/c/free-c-and-vb-coding-standards-reference-documents/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>VS 2010 and .NET 4.0</title>
		<link>http://osman.it/c/vs-2010-and-net-40/</link>
		<comments>http://osman.it/c/vs-2010-and-net-40/#comments</comments>
		<pubDate>Thu, 18 Dec 2008 20:46:25 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[VS 2010 and .NET 4.0]]></category>

		<guid isPermaLink="false">http://mdosman.us/?p=179</guid>
		<description><![CDATA[Visual Studio 2010 and .NET Framework 4.0 CTP Feedback ______________________________________________________________ ______________________________________________________________ &#160; Feedback &#160;&#160;&#160;Home&#160;&#160;&#160; &#160;&#160;&#160;&#160;CTP&#160;&#160;&#160;&#160;&#160; Download Feedback &#160;&#160;Forums&#160; &#160;&#160;&#160;&#160;&#160;FAQ&#160;&#160;&#160;&#160; &#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &#160;&#160;Help &#38;&#160;&#160;&#160; &#160;&#160;Contact&#160;&#160; &#160; © admin for Mohammed Osman, 2008. &#124; Permalink &#124; No comment &#124; Add to del.icio.us Post tags: VS 2010 and .NET 4.0 Feed enhanced by Better Feed from Ozh]]></description>
			<content:encoded><![CDATA[<p><span class="headingmajor"><font size="6">Visual Studio 2010 and .NET Framework 4.0 CTP Feedback</font></span> <br />
<meta content="Microsoft SafeHTML" name="Generator" /><br />
<style type="text/css">
.Default
{text-align:center;color:#1162BB;}
.MenuArea
{text-align:center;}
.headingmajor,
{font-family:Arial, Helvetica, sans-serif;font-size:1.7em;color:black;text-align:center;}
.TitleArea,
{font-family:Arial, Helvetica, sans-serif;font-size:1.7em;color:#1162BB;text-align:center;}
.TextArea
{text-align:center;}
.MenuText
{font-family:Arial, Helvetica, sans-serif;font-size:1em;color:#1162BB;text-align:center;font-weight:bold;}
.MenuText a:link
{color:#1162BB;background:#FFFFFF;text-decoration:none;}
.MenuText a:visited
{color:#1162BB;background:#FFFFFF;text-decoration:none;}
.MenuText a:hover
{color:#FFFFFF;background:#1162BB;text-decoration:none;}
.MenuText a:active
{color:#1162BB;background:#FFFFFF;text-decoration:none;}
.MenuTable
{text-align:center;border-color:#1162BB;border:1px solid #1162BB;}
.Paragraphs
{font-family:Arial, Helvetica, sans-serif;text-align:left;}
.BoxHeader
{text-align:left;font-family:Arial, Helvetica, sans-serif;font-size:large;background:#1162BB;color:#FFFFFF;}
.Special
{text-align:left;font-family:Arial, Helvetica, sans-serif;font-size:large;background:#FF0000;color:#FFFFFF;}
.BoxText
{text-align:left;font-family:Arial, Helvetica, sans-serif;color:black;border-color:#1162BB;border-width:1px;}
.style1
{border:thin solid #1162BB;}
.style2
{border:thin solid #FF0000;}</style>
</p>
<div class="TitleArea">______________________________________________________________ <img height="47" alt="Visual Studio 2010 &amp; .Net Framework 4.0 Logo" width="486" src="https://connect.microsoft.com/visualstudio/siteimages/f2b64570-4956-4687-b2d7-58842cabbbe8.jpg" /> ______________________________________________________________</div>
<p>
&nbsp;</p>
<div class="MenuArea">
<table class="MenuTable">
<tbody>
<tr>
<td>
<table class="MenuTable">
<tbody>
<tr>
<td class="MenuText"><a href="https://connect.microsoft.com/VisualStudio/content/content.aspx?ContentID=9790"><img height="60" alt="CTP Feedback Home" width="60" src="https://connect.microsoft.com/visualstudio/siteimages/03e99cbd-7030-4e6a-abd2-7a359392be70.jpg" /> </a></td>
</tr>
<tr>
<td class="MenuText"><a href="https://connect.microsoft.com/VisualStudio/content/content.aspx?ContentID=9790">Feedback <br />
                        &nbsp;&nbsp;&nbsp;Home&nbsp;&nbsp;&nbsp; </a></td>
</tr>
</tbody>
</table>
</td>
<td>
<table class="MenuTable">
<tbody>
<tr>
<td><a href="http://go.microsoft.com/fwlink/?LinkId=131310"><img height="60" alt="Download CTP" width="60" src="https://connect.microsoft.com/visualstudio/siteimages/01adcb6b-2f31-4b2f-8b3b-47d690a97826.jpg" /> </a></td>
</tr>
<tr>
<td class="MenuText"><a href="http://go.microsoft.com/fwlink/?LinkId=131310">&nbsp;&nbsp;&nbsp;&nbsp;CTP&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <br />
                        Download</a></td>
</tr>
</tbody>
</table>
</td>
<td>
<table class="MenuTable">
<tbody>
<tr>
<td><a href="http://social.msdn.microsoft.com/Forums/en-US/category/vs2010ctp"><img height="60" alt="Forums Icon" width="60" src="https://connect.microsoft.com/visualstudio/siteimages/08b46f88-6c77-4ed6-a502-e6501c749cce.gif" /> </a></td>
</tr>
<tr>
<td class="MenuText"><a href="http://social.msdn.microsoft.com/Forums/en-US/category/vs2010ctp">Feedback<br />
                        &nbsp;&nbsp;Forums&nbsp; </a></td>
</tr>
</tbody>
</table>
</td>
<td>
<table class="MenuTable">
<tbody>
<tr>
<td><a href="https://connect.microsoft.com/VisualStudio/content/content.aspx?ContentID=10046"><img height="60" alt="FAQ Icon" width="60" src="https://connect.microsoft.com/visualstudio/siteimages/0aaa7fd5-1fb6-4b37-b7ce-51fcf24d1f62.jpg" /> </a></td>
</tr>
<tr>
<td class="MenuText" style="height: 20px"><a href="https://connect.microsoft.com/VisualStudio/content/content.aspx?ContentID=10046">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;FAQ&nbsp;&nbsp;&nbsp;&nbsp; <br />
                        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </a></td>
</tr>
</tbody>
</table>
</td>
<td>
<table class="MenuTable">
<tbody>
<tr>
<td><a href="https://connect.microsoft.com/VisualStudio/content/content.aspx?ContentID=10047"><img height="60" alt="Help &amp; Contact" width="60" src="https://connect.microsoft.com/visualstudio/siteimages/dcd4c725-9477-44d2-a801-fe3f87a58248.jpg" /> </a></td>
</tr>
<tr>
<td class="MenuText"><a href="https://connect.microsoft.com/VisualStudio/content/content.aspx?ContentID=10047">&nbsp;&nbsp;Help &amp;&nbsp;&nbsp;&nbsp;<br />
                        &nbsp;&nbsp;Contact&nbsp;&nbsp; </a></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</div>
<p>
&nbsp;</p>
<img src="http://osman.it/?ak_action=api_record_view&id=179&type=feed" alt="" /><p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fosman.it%2Fc%2Fvs-2010-and-net-40%2F&amp;title=VS%202010%20and%20.NET%204.0" id="wpa2a_14"><img src="http://osman.it/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><hr />
<p><small>© admin for <a href="http://osman.it">Mohammed Osman</a>, 2008. |
<a href="http://osman.it/c/vs-2010-and-net-40/">Permalink</a> |
<a href="http://osman.it/c/vs-2010-and-net-40/#comments">No comment</a> |
Add to
<a href="http://del.icio.us/post?url=http://osman.it/c/vs-2010-and-net-40/&title=VS 2010 and .NET 4.0">del.icio.us</a>
<br/>
Post tags: <a href="http://osman.it/tag/vs-2010-and-net-40/" rel="tag">VS 2010 and .NET 4.0</a><br/>
</small></p>
<p><small>Feed enhanced by <a href='http://planetozh.com/blog/my-projects/wordpress-plugin-better-feed-rss/'>Better Feed</a> from  <a href='http://planetozh.com/blog/'>Ozh</a></small></p>
]]></content:encoded>
			<wfw:commentRss>http://osman.it/c/vs-2010-and-net-40/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

