<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.asp.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Yanesh Tyagi on ASP.Net</title><link>http://weblogs.asp.net/yaneshtyagi/default.aspx</link><description>Technical blog of Yanesh Tyagi</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>.NET Framework FX 4 Beta 1 – What’s New</title><link>http://weblogs.asp.net/yaneshtyagi/archive/2009/05/20/net-fx-4-beta-1-what-s-new.aspx</link><pubDate>Tue, 19 May 2009 19:18:35 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7093001</guid><dc:creator>Yanesh Tyagi</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/rsscomments.aspx?PostID=7093001</wfw:commentRss><wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/commentapi.aspx?PostID=7093001</wfw:comment><comments>http://weblogs.asp.net/yaneshtyagi/archive/2009/05/20/net-fx-4-beta-1-what-s-new.aspx#comments</comments><description>&lt;p&gt;Today, Microsoft launched &lt;a href="http://www.microsoft.com/visualstudio/en-us/products/2010/default.mspx" target="_blank"&gt;Visual Studio 2010&lt;/a&gt; and &lt;a href="http://www.microsoft.com/net" target="_blank"&gt;.Net FX 4 Beta 1&lt;/a&gt;. This is available to the MSDN subscribers only. Don’t loose heart. It will be available to everybody on &lt;a href="http://blogs.msdn.com/somasegar/archive/2009/05/18/visual-studio-2010-and-net-fx-4-beta-1-ships.aspx"&gt;Wednesday&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;.Net Framework 4.0 will provide the second generation of WCF and WWF. Together, these two technologies integrates naturally. This will allow developers to better model complex communication patterns in a full declarative language (XAML).&lt;/p&gt;  &lt;p&gt;&lt;b&gt;New Features of WCF:&lt;/b&gt;&lt;/p&gt;  &lt;ol&gt;   &lt;li&gt;&lt;b&gt;Representational state transfer (REST) enhancements&lt;/b&gt;       &lt;ol&gt;       &lt;li&gt;Simplified building of &lt;a href="http://www.msdn.com/wcf/rest"&gt;RESTful&lt;/a&gt; services &lt;/li&gt;        &lt;li&gt;Templates to accelerate building Singleton &amp;amp; Collection Services, Atom Feed and Publishing Protocol Services, and HTTP Plain XML Services &lt;/li&gt;     &lt;/ol&gt;   &lt;/li&gt;    &lt;li&gt;&lt;b&gt;Messaging enhancements&lt;/b&gt;       &lt;ol&gt;       &lt;li&gt;Protocols: WS-Discovery, WS-I BP 1.2 &lt;/li&gt;        &lt;li&gt;Duplex durable messaging &lt;/li&gt;     &lt;/ol&gt;   &lt;/li&gt;    &lt;li&gt;&lt;b&gt;Correlation enhancements&lt;/b&gt;       &lt;ol&gt;       &lt;li&gt;Content- and context-driven, one-way support &lt;/li&gt;     &lt;/ol&gt;   &lt;/li&gt;    &lt;li&gt;&lt;b&gt;Declarative workflow services&lt;/b&gt;       &lt;ol&gt;       &lt;li&gt;Seamless integration between Windows Workflow Foundation and Windows Communication Foundation and unified Extensible Application Markup Language (XAML) model &lt;/li&gt;        &lt;li&gt;Ability to build an entire application in XAML, from presentation to data to services to workflow &lt;/li&gt;     &lt;/ol&gt;   &lt;/li&gt; &lt;/ol&gt;  &lt;p&gt;&lt;strong&gt;New Features of WWF:&lt;/strong&gt;&lt;/p&gt;  &lt;ol&gt;   &lt;li&gt;&lt;b&gt;Significant improvements in performance and scalability&lt;/b&gt;       &lt;ol&gt;       &lt;li&gt;Performance gains in all aspects of Windows Workflow Foundation at design time and runtime &lt;/li&gt;        &lt;li&gt;At least a tenfold improvement in performance &lt;/li&gt;        &lt;li&gt;Improvements in serialization performance and size needs &lt;/li&gt;     &lt;/ol&gt;   &lt;/li&gt;    &lt;li&gt;&lt;b&gt;New workflow flow-control models and prebuilt activities&lt;/b&gt;       &lt;ol&gt;       &lt;li&gt;New flowchart control model &lt;/li&gt;        &lt;li&gt;Expanded built-in activities: Windows PowerShell, database, messaging, etc. &lt;/li&gt;     &lt;/ol&gt;   &lt;/li&gt;    &lt;li&gt;&lt;b&gt;Enhancements in workflow modeling&lt;/b&gt;       &lt;ol&gt;       &lt;li&gt;Persistence control, transaction flow, compensation support, data binding and variable/argument scoping&lt;b&gt;&lt;/b&gt; &lt;/li&gt;     &lt;/ol&gt;   &lt;/li&gt;    &lt;li&gt;&lt;b&gt;Updated visual designer&lt;/b&gt;       &lt;ol&gt;       &lt;li&gt;Easier to use by end users &lt;/li&gt;        &lt;li&gt;Easier to rehost by independent software vendors (ISVs) &lt;/li&gt;        &lt;li&gt;Ability to debug XAML &lt;/li&gt;     &lt;/ol&gt;   &lt;/li&gt; &lt;/ol&gt;  &lt;p&gt;&lt;strong&gt;Other features&lt;/strong&gt; in Version 4 includes:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/Task_Parallel_Library#TPL" target="_blank"&gt;Parallel Extensions&lt;/a&gt; to improve support for parallel computing, which target multi-core or distributed systems.&lt;/li&gt;    &lt;li&gt;New technology called &lt;a href="http://en.wikipedia.org/wiki/Task_Parallel_Library#TPL" target="_blank"&gt;PLINQ&lt;/a&gt; (Parallel LINQ),&amp;#160; a parallel implementation of the LINQ engine,&amp;#160; for parallel computing.&lt;/li&gt;    &lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/Task_Parallel_Library#TPL" target="_blank"&gt;Task Parallel Library&lt;/a&gt;&amp;#160; which exposes parallel constructs via method calls.&lt;/li&gt;    &lt;li&gt;Full support for &lt;a href="http://www.codeplex.com/IronPython" target="_blank"&gt;IronPython&lt;/a&gt;, &lt;a href="http://www.ironruby.net/" target="_blank"&gt;IronRuby&lt;/a&gt;, and new language &lt;a href="http://research.microsoft.com/en-us/um/cambridge/projects/fsharp/default.aspx" target="_blank"&gt;F#&lt;/a&gt;.&lt;/li&gt;    &lt;li&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/cc709420.aspx" target="_blank"&gt;Oslo&lt;/a&gt; modelling platform, along with the &lt;a href="http://msdn.microsoft.com/en-us/library/dd285271.aspx" target="_blank"&gt;M&lt;/a&gt; programming language.&lt;/li&gt;    &lt;li&gt;Event Tracing for Windows&lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;To get the latest updates, keep watching &lt;a href="http://www.microsoft.com/net"&gt;Microsoft .Net Framework Page&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Related Links:&lt;/strong&gt;&lt;/p&gt;  &lt;ol&gt;   &lt;li&gt;&lt;a href="http://en.wikipedia.org/wiki/.NET_Framework" target="_blank"&gt;Comprehensive summary of all versions on .Net Framework&lt;/a&gt;&lt;/li&gt;    &lt;li&gt;&lt;a href="http://dario.blog.viadis.hr/2009/05/visual-studio-2010net-framework-4-first.html" target="_blank"&gt;Dario F spent a few hours on Visual Studio 2010/.Net Framework 4.0&lt;/a&gt;&lt;/li&gt;    &lt;li&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/w0x726c2(VS.100).aspx" target="_blank"&gt;MSDN Page for .Net Framework 4.0 Beta 1&lt;/a&gt;&lt;/li&gt;    &lt;li&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/dd831853(VS.100).aspx" target="_blank"&gt;MSDN Page for Visual Studio 2010&lt;/a&gt;&lt;/li&gt;    &lt;li&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/ms754130(VS.100).aspx" target="_blank"&gt;WPF for .Net Framework 4.0&lt;/a&gt;&lt;/li&gt;    &lt;li&gt;&lt;a href="http://blogs.msdn.com/wpfsdk/" target="_blank"&gt;WPF Blog&lt;/a&gt;&lt;/li&gt; &lt;/ol&gt;  &lt;p&gt;&lt;strong&gt;Download .Net Framework 4&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;You can download .Net Framework FX 4 Beta 1 from &lt;a href="http://msdn.microsoft.com/en-us/subscriptions/downloads/default.aspx?pv=18:370" target="_blank"&gt;here&lt;/a&gt;. Download is available to the MSDN subscribers only. The link mentioned here required you to login into the MSDN Site. &lt;a href="http://blogs.msdn.com/somasegar/archive/2009/05/18/visual-studio-2010-and-net-fx-4-beta-1-ships.aspx" target="_blank"&gt;Soma&lt;/a&gt; says that MSDN non-subscribers can download the Framework 4.0 on Wednesday.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt; &lt;a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fweblogs.asp.net%2fyaneshtyagi%2farchive%2f2009%2f05%2f20%2fnet-fx-4-beta-1-what-s-new.aspx"&gt;&lt;img src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fweblogs.asp.net%2fyaneshtyagi%2farchive%2f2009%2f05%2f20%2fnet-fx-4-beta-1-what-s-new.aspx" border="0" alt="kick it on DotNetKicks.com" /&gt;&lt;/a&gt; &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;div style="padding-bottom: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; float: none; padding-top: 0px" id="scid:0767317B-992E-4b12-91E0-4F059A8CECA8:c30b6e2d-d8fb-4dc4-bda3-41dfdec32996" class="wlWriterEditableSmartContent"&gt;Technorati Tags: &lt;a href="http://technorati.com/tags/ASP.Net+Framework+4.0" rel="tag"&gt;ASP.Net Framework 4.0&lt;/a&gt;&lt;/div&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7093001" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/ASP.NET/default.aspx">ASP.NET</category></item><item><title>Code Snippet for Automatically Implemented Property</title><link>http://weblogs.asp.net/yaneshtyagi/archive/2009/02/04/code-snippet-for-automatically-implemented-property.aspx</link><pubDate>Tue, 03 Feb 2009 18:04:37 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:6879051</guid><dc:creator>Yanesh Tyagi</dc:creator><slash:comments>3</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/rsscomments.aspx?PostID=6879051</wfw:commentRss><wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/commentapi.aspx?PostID=6879051</wfw:comment><comments>http://weblogs.asp.net/yaneshtyagi/archive/2009/02/04/code-snippet-for-automatically-implemented-property.aspx#comments</comments><description>&lt;p&gt;Code snippets allows programmers to extend auto-complete feature of Visual Studio. Code snippets enables a programmer to create an auto-complete that will appear in the intellisense. It also allows a programmer to define the logic of auto complete.&lt;/p&gt;  &lt;p&gt;Behind the hood, code snippets are the XML files in a pre-defined format. Visual Studio IDE reads these XML files and made them available in intellisense. To check code snippet in live, type 'if' in &lt;em&gt;c#&lt;/em&gt; code file and press tab two times. It inserts the skeleton of if structure automatically. This snippet came pre-installed with Visual Web Developer. But you can create your own snippets.&lt;/p&gt;  &lt;p&gt;Visual Web Developer 2008 Express Edition provides two code snippets for properties - &lt;em&gt;prop&lt;/em&gt; and &lt;em&gt;propg&lt;/em&gt;. &lt;em&gt;Prop&lt;/em&gt; inserts code for a regular property and &lt;em&gt;propg&lt;/em&gt; inserts code for automatically implemented property with private set accessor. But in most cases we require automatically inserted property with &lt;em&gt;get&lt;/em&gt; and &lt;em&gt;set&lt;/em&gt; accessors having public access as in the code below:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;span style="color: blue"&gt;public int &lt;/span&gt;MyProperty { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Here is the code snippet for this. &lt;/p&gt;  &lt;h4&gt;propa.snippet file&lt;/h4&gt;  &lt;pre class="code"&gt;&lt;span style="color: blue"&gt;&amp;lt;?&lt;/span&gt;&lt;span style="color: #a31515"&gt;xml &lt;/span&gt;&lt;span style="color: red"&gt;version&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&amp;quot;&lt;span style="color: blue"&gt;1.0&lt;/span&gt;&amp;quot; &lt;span style="color: red"&gt;encoding&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&amp;quot;&lt;span style="color: blue"&gt;utf-8&lt;/span&gt;&amp;quot; &lt;span style="color: blue"&gt;?&amp;gt;
&amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;CodeSnippets  &lt;/span&gt;&lt;span style="color: red"&gt;xmlns&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&amp;quot;&lt;span style="color: blue"&gt;http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet&lt;/span&gt;&amp;quot;&lt;span style="color: blue"&gt;&amp;gt;
    &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;CodeSnippet &lt;/span&gt;&lt;span style="color: red"&gt;Format&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&amp;quot;&lt;span style="color: blue"&gt;1.0.0&lt;/span&gt;&amp;quot;&lt;span style="color: blue"&gt;&amp;gt;
        &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Header&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
            &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Title&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;/span&gt;propa&lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Title&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
            &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Shortcut&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;/span&gt;propa&lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Shortcut&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
            &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Description&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;/span&gt;Code snippet for an automatically implemented property with 'get' and 'set' accessors&lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Description&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
            &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Author&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;/span&gt;Yanesh Tyagi&lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Author&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
            &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;SnippetTypes&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
                &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;SnippetType&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;/span&gt;Expansion&lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;SnippetType&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
            &amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;SnippetTypes&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
        &amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Header&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
        &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Snippet&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
            &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Declarations&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
                &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Literal&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
                    &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;ID&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;/span&gt;type&lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;ID&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
                    &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;ToolTip&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;/span&gt;Property type&lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;ToolTip&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
                    &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Default&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;/span&gt;int&lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Default&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
                &amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Literal&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
                &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Literal&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
                    &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;ID&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;/span&gt;property&lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;ID&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
                    &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;ToolTip&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;/span&gt;Property name&lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;ToolTip&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
                    &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Default&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;/span&gt;MyProperty&lt;span style="color: blue"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Default&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
                &amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Literal&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
            &amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Declarations&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
            &amp;lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Code &lt;/span&gt;&lt;span style="color: red"&gt;Language&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&amp;quot;&lt;span style="color: blue"&gt;csharp&lt;/span&gt;&amp;quot;&lt;span style="color: blue"&gt;&amp;gt;&amp;lt;![CDATA[&lt;/span&gt;&lt;span style="color: gray"&gt;public $type$ $property$ { get; set; }$end$&lt;/span&gt;&lt;span style="color: blue"&gt;]]&amp;gt;
            &amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Code&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
        &amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Snippet&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
    &amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;CodeSnippet&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;
&amp;lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;CodeSnippets&lt;/span&gt;&lt;span style="color: blue"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;

&lt;h4&gt;What Does This XML Mean:&lt;/h4&gt;

&lt;p&gt;The code snippet XML has two sections - &amp;lt;Header&amp;gt; and &amp;lt;Snippet&amp;gt;. Header contains snippet's meta data like title, shortcut, description etc. The text in the &amp;lt;Shortcut&amp;gt; section appears in the intellisense. The other section &amp;lt;Snippet&amp;gt; contains the actual data that will be inserted. The actual text that will be inserted is defined in the &amp;lt;Code&amp;gt; section. Note that the replaceable sections are sandwiched between '$'. Scott Mitchell describes the code snippets in more details in his &lt;a href="http://aspnet.4guysfromrolla.com/articles/122105-1.aspx"&gt;article&lt;/a&gt; at 4Guys.&amp;#160; &lt;/p&gt;

&lt;h4&gt;How To Install:&lt;/h4&gt;

&lt;ol&gt;
  &lt;li&gt;Create an xml file and name it propa.snippet. &lt;/li&gt;

  &lt;li&gt;Save this file in My Documents\Visual Studio 2008\Code Snippets\Visual C#\My Code Snippets folder. VWD IDE automatically reads the snippets from this folder. &lt;/li&gt;
&lt;/ol&gt;

&lt;h4&gt;&lt;/h4&gt;

&lt;h4&gt;How To Use&lt;/h4&gt;

&lt;p&gt;Place the cursor where you want to insert the snippet in &lt;em&gt;c#&lt;/em&gt; code file. Type &lt;em&gt;propa &lt;/em&gt;and press tab two times. The following code will be inserted at the location of cursor.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;&lt;span style="color: blue"&gt;public int &lt;/span&gt;MyProperty { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The following image shows &lt;em&gt;propa &lt;/em&gt;snippet in action.&lt;/p&gt;

&lt;p&gt;&lt;a href="http://weblogs.asp.net/blogs/yaneshtyagi/WindowsLiveWriter/CodeSnippetforAutomaticallyImplementedPr_14683/image_2.png"&gt;&lt;img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="201" alt="image" src="http://weblogs.asp.net/blogs/yaneshtyagi/WindowsLiveWriter/CodeSnippetforAutomaticallyImplementedPr_14683/image_thumb.png" width="725" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;&lt;a href="http://yaneshtyagi.com/Download/Demo/propa.zip"&gt;Download&lt;/a&gt; this xml file ( 1kb zip).&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fweblogs.asp.net%2fyaneshtyagi%2farchive%2f2009%2f02%2f04%2fcode-snippet-for-automatically-implemented-property.aspx"&gt;&lt;img alt="kick it on DotNetKicks.com" src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fweblogs.asp.net%2fyaneshtyagi%2farchive%2f2009%2f02%2f04%2fcode-snippet-for-automatically-implemented-property.aspx" border="0" /&gt;&lt;/a&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6879051" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/Code+Snippet/default.aspx">Code Snippet</category></item><item><title>Mystery of Not Operator in VB.Net</title><link>http://weblogs.asp.net/yaneshtyagi/archive/2009/02/03/mystery-of-not-operator-in-vb-net.aspx</link><pubDate>Tue, 03 Feb 2009 08:59:03 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:6878758</guid><dc:creator>Yanesh Tyagi</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/rsscomments.aspx?PostID=6878758</wfw:commentRss><wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/commentapi.aspx?PostID=6878758</wfw:comment><comments>http://weblogs.asp.net/yaneshtyagi/archive/2009/02/03/mystery-of-not-operator-in-vb-net.aspx#comments</comments><description>&lt;p&gt;(Not 2) = -3. &lt;/p&gt; &lt;p&gt;Strange! &lt;/p&gt; &lt;p&gt;Read below.&lt;/p&gt; &lt;p&gt;In VB.Net, non-zero integer is evaluated as True and an integer whose value is zero is evaluated as False. This is known fact since earliest version of Visual Basic. And this is also supported by VB.Net.&lt;/p&gt; &lt;p&gt;Now consider following code:&lt;/p&gt;&lt;pre class="code"&gt;&lt;span style="color: blue"&gt;Protected Sub &lt;/span&gt;Page_Load(&lt;span style="color: blue"&gt;ByVal &lt;/span&gt;sender &lt;span style="color: blue"&gt;As Object&lt;/span&gt;, &lt;span style="color: blue"&gt;ByVal &lt;/span&gt;e &lt;span style="color: blue"&gt;As &lt;/span&gt;System.EventArgs) &lt;span style="color: blue"&gt;Handles Me&lt;/span&gt;.Load
    &lt;span style="color: blue"&gt;Dim &lt;/span&gt;x &lt;span style="color: blue"&gt;As Integer &lt;/span&gt;= 2    &lt;span style="color: green"&gt;'non zero integer is so x = True
    &lt;/span&gt;&lt;span style="color: blue"&gt;If Not &lt;/span&gt;x &lt;span style="color: blue"&gt;Then   &lt;/span&gt;&lt;span style="color: green"&gt;'not True i.e. False
        &lt;/span&gt;Response.Write(&lt;span style="color: #a31515"&gt;"X is False and the value of x is: " &lt;/span&gt;&amp;amp; &lt;span style="color: blue"&gt;Not &lt;/span&gt;x)
    &lt;span style="color: blue"&gt;Else
        &lt;/span&gt;Response.Write(&lt;span style="color: #a31515"&gt;"True"&lt;/span&gt;)
    &lt;span style="color: blue"&gt;End If
End Sub&lt;/span&gt;&lt;/pre&gt;
&lt;p&gt;&lt;a href="http://11011.net/software/vspaste"&gt;&lt;/a&gt;Now there are two questions:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;What will be printed on the page: value of x or True. 
&lt;li&gt;If value of x will be printed, what will be the value of x?&lt;/li&gt;&lt;/ol&gt;
&lt;p&gt;When I run the page, It printed &lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;X is False and the value of x is: -3&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;which is strange, isn't it? I initialized x with 2. Since this is a non-zero integer, it should be True. So 'Not x' should be evaluated as False in the if condition and else part should be executed. This is supposed to print "True" on the page. But this is not the case.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;The Mystery of Not&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Investigating the issue, I found that &lt;a href="http://yaneshtyagi.blogspot.com/2008/06/true-false-in-classic-vb.html"&gt;NOT was a bit-wise operator in classical Visual Basic&lt;/a&gt;. It exhibits the same behavior in VB.Net. SO considering the bit-wise calculations,&lt;/p&gt;
&lt;p&gt;2 in Binary is 0000 0010.&lt;/p&gt;
&lt;p&gt;Not 2 will reverse the bit-pattern making it 1111 1101. Considering the last bit is a sign bit, 1111 1101 is -3 in decimal.&lt;/p&gt;
&lt;p&gt;So the if condition now becomes&lt;/p&gt;&lt;pre class="code"&gt;&lt;span style="color: blue"&gt;If Not &lt;/span&gt;x &lt;span style="color: blue"&gt;Then  &lt;/span&gt;&lt;/pre&gt;&lt;pre class="code"&gt;&lt;span style="color: blue"&gt;=&amp;gt; If -3 Then &lt;/span&gt;&lt;/pre&gt;&lt;pre class="code"&gt;&lt;span style="color: blue"&gt;=&amp;gt; If True &lt;/span&gt;(since -3 is non-zero integer, this is True)&lt;/pre&gt;&lt;pre class="code"&gt;&lt;/pre&gt;
&lt;p&gt;Hence it evaluated the If condition as true and printed the value of x as -3.&lt;/p&gt;
&lt;p&gt;This is strange but true.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://yaneshtyagi.com/Download/Demo/NotInVB.zip"&gt;Download&lt;/a&gt; source code for this post (4KB zip).&lt;/p&gt;
&lt;p&gt;&lt;a href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fweblogs.asp.net%2fyaneshtyagi%2farchive%2f2009%2f02%2f03%2fmystery-of-not-operator-in-vb-net.aspx"&gt;&lt;img alt="kick it on DotNetKicks.com" src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fweblogs.asp.net%2fyaneshtyagi%2farchive%2f2009%2f02%2f03%2fmystery-of-not-operator-in-vb-net.aspx" border="0"&gt;&lt;/a&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6878758" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/Concepts/default.aspx">Concepts</category><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/VB.Net/default.aspx">VB.Net</category></item><item><title>Implementing Sorting in Generic List (List&lt;T&gt;)</title><link>http://weblogs.asp.net/yaneshtyagi/archive/2009/01/27/implementing-sorting-in-generic-list-list-lt-t-gt.aspx</link><pubDate>Tue, 27 Jan 2009 08:19:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:6861293</guid><dc:creator>Yanesh Tyagi</dc:creator><slash:comments>7</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/rsscomments.aspx?PostID=6861293</wfw:commentRss><wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/commentapi.aspx?PostID=6861293</wfw:comment><comments>http://weblogs.asp.net/yaneshtyagi/archive/2009/01/27/implementing-sorting-in-generic-list-list-lt-t-gt.aspx#comments</comments><description>&lt;P&gt;How to sort a generic list? Well, generic list provides a sort method itself in the form List&amp;lt;T&amp;gt;.Sort(). But wait a sec. This method requires you to implement sorting mechanism in your type. This is because this method uses default sorting mechanism. This is really simple, but what if you don't have sorting mechanism in your type? In that case this method throws InvalidOperationExpression. &lt;/P&gt;
&lt;P&gt;List&amp;lt;T&amp;gt;.Sort() method uses the default comparer &lt;EM&gt;Comparer(T).Default&lt;/EM&gt; for type T to determine the order of list elements. The &lt;EM&gt;Comparer(T).Default&lt;/EM&gt; property checks whether type T implements the IComparable(T) generic interface and uses that implementation, if available. If not, &lt;EM&gt;Comparer(T).Default&lt;/EM&gt; checks whether type T implements the &lt;EM&gt;IComparable&lt;/EM&gt; interface. If type T does not implement either interface, &lt;EM&gt;Comparer(T).Default&lt;/EM&gt; throws an &lt;EM&gt;InvalidOperationException&lt;/EM&gt;.&lt;/P&gt;
&lt;P&gt;If you use system types like String, default comparer works fine. This is because String class implements &lt;EM&gt;IComparable&lt;/EM&gt; interface. If you see the definition of String class, it looks like (you can see this by pressing F12 keeping the cursor on the word 'String' in the code editor of visual studio):&lt;/P&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: blue"&gt;public sealed class &lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;String &lt;/SPAN&gt;: &lt;SPAN style="COLOR: #2b91af"&gt;IComparable&lt;/SPAN&gt;, &lt;SPAN style="COLOR: #2b91af"&gt;ICloneable&lt;/SPAN&gt;, &lt;SPAN style="COLOR: #2b91af"&gt;IConvertible&lt;/SPAN&gt;, 
                             &lt;SPAN style="COLOR: #2b91af"&gt;IComparable&lt;/SPAN&gt;&amp;lt;&lt;SPAN style="COLOR: blue"&gt;string&lt;/SPAN&gt;&amp;gt;, &lt;SPAN style="COLOR: #2b91af"&gt;IEnumerable&lt;/SPAN&gt;&amp;lt;&lt;SPAN style="COLOR: blue"&gt;char&lt;/SPAN&gt;&amp;gt;, 
                             IEnumerable, &lt;SPAN style="COLOR: #2b91af"&gt;IEquatable&lt;/SPAN&gt;&amp;lt;&lt;SPAN style="COLOR: blue"&gt;string&lt;/SPAN&gt;&amp;gt; &lt;/PRE&gt;&lt;PRE class=code&gt;&amp;nbsp;&lt;/PRE&gt;&lt;PRE class=code&gt;&lt;/PRE&gt;
&lt;P&gt;But for types that does not implement &lt;EM&gt;Icomparable&lt;/EM&gt;, default sort does not work. However there is one work around. This trick uses delegates.&lt;/P&gt;
&lt;P&gt;To illustrate this example, I created a simple class Post. The code of this class is as below. This class does not implement &lt;EM&gt;IComparable&lt;/EM&gt; interface. So default sort will not work for this. &lt;/P&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: blue"&gt;using &lt;/SPAN&gt;System;
&lt;SPAN style="COLOR: blue"&gt;using &lt;/SPAN&gt;System.Collections.Generic;
&lt;SPAN style="COLOR: blue"&gt;using &lt;/SPAN&gt;System.Linq;
&lt;SPAN style="COLOR: blue"&gt;using &lt;/SPAN&gt;System.Web;

&lt;SPAN style="COLOR: blue"&gt;namespace &lt;/SPAN&gt;Tyagi.Utility
{
    &lt;SPAN style="COLOR: blue"&gt;public class &lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;Post &lt;/SPAN&gt;: &lt;SPAN style="COLOR: #2b91af"&gt;IComparable&lt;/SPAN&gt;&amp;lt;&lt;SPAN style="COLOR: #2b91af"&gt;Post&lt;/SPAN&gt;&amp;gt;
    {
        &lt;SPAN style="COLOR: blue"&gt;public &lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;String &lt;/SPAN&gt;Title { &lt;SPAN style="COLOR: blue"&gt;get&lt;/SPAN&gt;; &lt;SPAN style="COLOR: blue"&gt;set&lt;/SPAN&gt;; }
        &lt;SPAN style="COLOR: blue"&gt;public &lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;String &lt;/SPAN&gt;Source { &lt;SPAN style="COLOR: blue"&gt;get&lt;/SPAN&gt;; &lt;SPAN style="COLOR: blue"&gt;set&lt;/SPAN&gt;; }
    }
}
&lt;/PRE&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;
&lt;P&gt;Create another class that will consume this class.&lt;/P&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: blue"&gt;using &lt;/SPAN&gt;System;
&lt;SPAN style="COLOR: blue"&gt;using &lt;/SPAN&gt;System.Collections.Generic;
&lt;SPAN style="COLOR: blue"&gt;using &lt;/SPAN&gt;System.Linq;
&lt;SPAN style="COLOR: blue"&gt;using &lt;/SPAN&gt;System.Web;

&lt;SPAN style="COLOR: blue"&gt;namespace &lt;/SPAN&gt;Tyagi.Utility
{
    &lt;SPAN style="COLOR: blue"&gt;public class &lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;PostsList
    &lt;/SPAN&gt;{
        &lt;SPAN style="COLOR: #2b91af"&gt;List&lt;/SPAN&gt;&amp;lt;&lt;SPAN style="COLOR: #2b91af"&gt;Post&lt;/SPAN&gt;&amp;gt; posts = &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;List&lt;/SPAN&gt;&amp;lt;&lt;SPAN style="COLOR: #2b91af"&gt;Post&lt;/SPAN&gt;&amp;gt;();

        &lt;SPAN style="COLOR: blue"&gt;public &lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;List&lt;/SPAN&gt;&amp;lt;&lt;SPAN style="COLOR: #2b91af"&gt;Post&lt;/SPAN&gt;&amp;gt; GelPosts()
        {
            posts.Add(&lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;Post &lt;/SPAN&gt;{ Title = &lt;SPAN style="COLOR: #a31515"&gt;"MSN Space"&lt;/SPAN&gt;, Source = &lt;SPAN style="COLOR: #a31515"&gt;"Blog" &lt;/SPAN&gt;});
            posts.Add(&lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;Post &lt;/SPAN&gt;{ Title = &lt;SPAN style="COLOR: #a31515"&gt;"CNBC TV 18"&lt;/SPAN&gt;, Source = &lt;SPAN style="COLOR: #a31515"&gt;"News" &lt;/SPAN&gt;});
            posts.Add(&lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: #2b91af"&gt;Post &lt;/SPAN&gt;{ Title = &lt;SPAN style="COLOR: #a31515"&gt;"Independence Day"&lt;/SPAN&gt;, Source = &lt;SPAN style="COLOR: #a31515"&gt;"Movie" &lt;/SPAN&gt;});

            posts.Sort(&lt;SPAN style="COLOR: blue"&gt;delegate&lt;/SPAN&gt;(&lt;SPAN style="COLOR: #2b91af"&gt;Post &lt;/SPAN&gt;P1, &lt;SPAN style="COLOR: #2b91af"&gt;Post &lt;/SPAN&gt;P2)
            {
                &lt;SPAN style="COLOR: blue"&gt;return &lt;/SPAN&gt;P1.Title.CompareTo(P2.Title);
            });

            &lt;SPAN style="COLOR: blue"&gt;return &lt;/SPAN&gt;posts;
        }
        
        
    }
}&lt;/PRE&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;
&lt;P&gt;The trick is in the use of a delegate in the call to Sort method of the posts object.&lt;/P&gt;&lt;PRE class=code&gt;posts.Sort(&lt;SPAN style="COLOR: blue"&gt;delegate&lt;/SPAN&gt;(&lt;SPAN style="COLOR: #2b91af"&gt;Post &lt;/SPAN&gt;P1, &lt;SPAN style="COLOR: #2b91af"&gt;Post &lt;/SPAN&gt;P2)
{
    &lt;SPAN style="COLOR: blue"&gt;return &lt;/SPAN&gt;P1.Title.CompareTo(P2.Title);
});&lt;/PRE&gt;
&lt;P&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;&lt;FONT face="Courier New"&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;The delegate accepts two parameter, both of the same class Post. It the uses the &lt;EM&gt;CompareTo&lt;/EM&gt; method. This method is defined in the type of property. In this example, Title property of Post class is of type string. So the &lt;EM&gt;CompareTo&lt;/EM&gt; method of string class will be called in this case. &lt;EM&gt;CompareTo&lt;/EM&gt; method returns &lt;EM&gt;int&lt;/EM&gt;. Sort method of List&amp;lt;T&amp;gt; uses this integer to compare two objects.&lt;/P&gt;
&lt;P&gt;The above code returns list in the ascending order of title. To reverse the order, simply reverse the code as be below:&lt;/P&gt;&lt;PRE class=code&gt;posts.Sort(&lt;SPAN style="COLOR: blue"&gt;delegate&lt;/SPAN&gt;(&lt;SPAN style="COLOR: #2b91af"&gt;Post &lt;/SPAN&gt;P1, &lt;SPAN style="COLOR: #2b91af"&gt;Post &lt;/SPAN&gt;P2)
{
    &lt;SPAN style="COLOR: blue"&gt;return &lt;/SPAN&gt;P2.Title.CompareTo(P1.Title);
});
&lt;/PRE&gt;
&lt;P&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This is one way. You can implement the sorting functionality in your class as well. I will discuss this in the next post.&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fweblogs.asp.net%2fyaneshtyagi%2farchive%2f2009%2f01%2f27%2fimplementing-sorting-in-generic-list-list-lt-t-gt.aspx"&gt;&lt;IMG alt="kick it on DotNetKicks.com" src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fweblogs.asp.net%2fyaneshtyagi%2farchive%2f2009%2f01%2f27%2fimplementing-sorting-in-generic-list-list-lt-t-gt.aspx" border=0&gt;&lt;/A&gt; &lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6861293" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/C_2300_/default.aspx">C#</category><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/Generics/default.aspx">Generics</category><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/List_2600_lt_3B00_T_2600_gt_3B00_/default.aspx">List&amp;lt;T&amp;gt;</category></item><item><title>Implementing Delete Confirmation Dialog in ListView Control (ASP.Net)</title><link>http://weblogs.asp.net/yaneshtyagi/archive/2009/01/21/implementing-delete-confirmation-dialog-in-listview-control-asp-net.aspx</link><pubDate>Tue, 20 Jan 2009 18:34:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:6848380</guid><dc:creator>Yanesh Tyagi</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/rsscomments.aspx?PostID=6848380</wfw:commentRss><wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/commentapi.aspx?PostID=6848380</wfw:comment><comments>http://weblogs.asp.net/yaneshtyagi/archive/2009/01/21/implementing-delete-confirmation-dialog-in-listview-control-asp-net.aspx#comments</comments><description>&lt;P&gt;Listview control is one of my favorite controls added in asp.net version 3.5. It provides easy way to implement view (list), update, insert and delete functionality. Using SQL Data Source or LINQ Data Source control, you can create a page that will display data from database in your desired format. It will also allow you to edit, insert or delete a record from the listview itself. And the good part is that you don't need to write any code. This may be disappointing to a hard core programmer like me. But again this saves lot of development time.&lt;/P&gt;
&lt;P&gt;But one of the lacking feature in the listview control is delete confirmation. If somebody clicks on the delete button by mistake, there is no way to cancel the delete action. To solve this issue, I used client side JavaScript and &lt;A href="http://www.wikihow.com/Use-the-Javascript-Confirm-Function" target=_blank mce_href="http://www.wikihow.com/Use-the-Javascript-Confirm-Function"&gt;confirm function&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;JavaScript's confirm function display an modal alert popup with the user specified confirmation message. It also have two buttons - OK and Cancel. Pressing OK or Cancel return boolean true or false. When confirm function is used with form submission, it cancels the form submission if Cancel button is pressed by the user. If user presses OK button, form submits as usual.&lt;/P&gt;
&lt;P&gt;I used confirm function in the OnClientClick event of the ListView's delete button.The code to use this is given below. Please note that in the code I used LinkButton instead of auto generated Button. This is for usability purpose and the code works well with the Button also.&lt;/P&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: blue"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #a31515"&gt;asp&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;:&lt;/SPAN&gt;&lt;SPAN style="COLOR: #a31515"&gt;LinkButton &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;ID&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;="DeleteButton" &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;runat&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;="server" &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;CommandName&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;="Delete" &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;ForeColor&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;="Red" &lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;Text&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;="Delete"
&lt;/SPAN&gt;&lt;SPAN style="COLOR: red"&gt;OnClientClick&lt;/SPAN&gt;&lt;SPAN style="COLOR: blue"&gt;="return confirm('Are you certain you want to delete?');" /&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;And the dialog box shown by this code is : &lt;/P&gt;
&lt;P&gt;&lt;A href="http://weblogs.asp.net/blogs/yaneshtyagi/WindowsLiveWriter/ImplementingDeleteConfirmationDialog.Net_14ABB/image_2.png" mce_href="http://weblogs.asp.net/blogs/yaneshtyagi/WindowsLiveWriter/ImplementingDeleteConfirmationDialog.Net_14ABB/image_2.png"&gt;&lt;IMG style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px" height=196 alt=image src="http://weblogs.asp.net/blogs/yaneshtyagi/WindowsLiveWriter/ImplementingDeleteConfirmationDialog.Net_14ABB/image_thumb.png" width=501 border=0 mce_src="http://weblogs.asp.net/blogs/yaneshtyagi/WindowsLiveWriter/ImplementingDeleteConfirmationDialog.Net_14ABB/image_thumb.png"&gt;&lt;/A&gt; &lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;&lt;/P&gt;&lt;A href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fweblogs.asp.net%2fyaneshtyagi%2farchive%2f2009%2f01%2f21%2fimplementing-delete-confirmation-dialog-in-listview-control-asp-net.aspx"&gt;&lt;IMG alt="kick it on DotNetKicks.com" src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fweblogs.asp.net%2fyaneshtyagi%2farchive%2f2009%2f01%2f21%2fimplementing-delete-confirmation-dialog-in-listview-control-asp-net.aspx" border=0&gt;&lt;/A&gt; &lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6848380" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/ASP.NET/default.aspx">ASP.NET</category><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/ListView/default.aspx">ListView</category></item><item><title>Converting Text into Image On-The-Fly</title><link>http://weblogs.asp.net/yaneshtyagi/archive/2008/11/07/text-to-image-convertor.aspx</link><pubDate>Fri, 07 Nov 2008 03:36:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:6724835</guid><dc:creator>Yanesh Tyagi</dc:creator><slash:comments>12</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/rsscomments.aspx?PostID=6724835</wfw:commentRss><wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/commentapi.aspx?PostID=6724835</wfw:comment><comments>http://weblogs.asp.net/yaneshtyagi/archive/2008/11/07/text-to-image-convertor.aspx#comments</comments><description>&lt;P&gt;Sometimes we need to convert text into the images on the fly. This code converts the text into image and displays it onto the web page without saving it into a file on the disk. It also takes care of text wrapping.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;TextToImageConvertor can either be used in a web page or in a module. I have used this code in a web page. To use TextToImageConvertor in a module, you will need to make some changes in the step 8.&lt;/P&gt;
&lt;P&gt;The code for TextToImageConvertor is self explanatory. However, I am going to describe this step-by-step.&lt;/P&gt;
&lt;P&gt;&lt;B&gt;Step 0 - Include Namespaces&lt;/B&gt;&lt;/P&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: blue"&gt;using &lt;/SPAN&gt;System.Drawing;&lt;BR&gt;&lt;SPAN style="COLOR: blue"&gt;using &lt;/SPAN&gt;System.Drawing.Imaging;&lt;/PRE&gt;
&lt;P&gt;&lt;B&gt;Step 1 - Declare Properties&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;Declare some variables that will control the behavior and color of the image.&lt;/P&gt;
&lt;P&gt;&lt;SPAN style="COLOR: blue"&gt;string &lt;/SPAN&gt;Text = Request.QueryString[&lt;SPAN style="COLOR: rgb(163,21,21)"&gt;"Text"&lt;/SPAN&gt;]; &lt;BR&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Color &lt;/SPAN&gt;FontColor = &lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Color&lt;/SPAN&gt;.Blue; &lt;BR&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Color &lt;/SPAN&gt;BackColor = &lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Color&lt;/SPAN&gt;.White; &lt;BR&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;String &lt;/SPAN&gt;FontName = &lt;SPAN style="COLOR: rgb(163,21,21)"&gt;"Times New Roman"&lt;/SPAN&gt;; &lt;BR&gt;&lt;SPAN style="COLOR: blue"&gt;int &lt;/SPAN&gt;FontSize = 10; &lt;BR&gt;&lt;SPAN style="COLOR: blue"&gt;int &lt;/SPAN&gt;Height = 150; &lt;BR&gt;&lt;SPAN style="COLOR: blue"&gt;int &lt;/SPAN&gt;Width = 150;&lt;/P&gt;
&lt;P&gt;&lt;B&gt;Step 2 - Create a Bitmap Object to Hold The Image&lt;/B&gt;&lt;/P&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Bitmap &lt;/SPAN&gt;bitmap = &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Bitmap&lt;/SPAN&gt;(Width, Height);&lt;/PRE&gt;
&lt;P&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;&lt;B&gt;Step 3 - Create a Graphics object using this Bitmap object&lt;/B&gt;&lt;/P&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Graphics &lt;/SPAN&gt;graphics = &lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Graphics&lt;/SPAN&gt;.FromImage(bitmap);&lt;/PRE&gt;
&lt;P&gt;&lt;B&gt;Step 4 - Create Color, Font, and&amp;nbsp; PointF objects.&lt;/B&gt;&lt;/P&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Color &lt;/SPAN&gt;color = &lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Color&lt;/SPAN&gt;.Gray; ;&lt;BR&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Font &lt;/SPAN&gt;font = &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Font&lt;/SPAN&gt;(FontName, FontSize);&lt;/PRE&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: green"&gt;//define where the text will be displayed in the specified area of the image&lt;BR&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;PointF &lt;/SPAN&gt;point = &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;PointF&lt;/SPAN&gt;(5.0F, 5.0F);&lt;/PRE&gt;
&lt;P&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;&lt;B&gt;Step 5 - Create Brushes and Pen&lt;/B&gt;&lt;/P&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;SolidBrush &lt;/SPAN&gt;BrushForeColor = &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;SolidBrush&lt;/SPAN&gt;(FontColor);&lt;BR&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;SolidBrush &lt;/SPAN&gt;BrushBackColor = &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;SolidBrush&lt;/SPAN&gt;(BackColor);&lt;BR&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Pen &lt;/SPAN&gt;BorderPen = &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Pen&lt;/SPAN&gt;(color);&lt;/PRE&gt;
&lt;P&gt;&lt;B&gt;Step 6 - Draw Rectangle using Graphics object&lt;/B&gt;&lt;/P&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Rectangle &lt;/SPAN&gt;displayRectangle = &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Rectangle&lt;/SPAN&gt;(&lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Point&lt;/SPAN&gt;(0, 0), &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Size&lt;/SPAN&gt;(Width - 1, Height - 1));&lt;BR&gt;graphics.FillRectangle(BrushBackColor, displayRectangle);&lt;BR&gt;graphics.DrawRectangle(BorderPen, displayRectangle);&lt;/PRE&gt;&lt;PRE class=code&gt;&lt;B&gt;&lt;FONT face="Trebuchet MS"&gt;Step 7 - Draw Text string on the specified rectangle using Graphics object&lt;/FONT&gt;&lt;/B&gt;&lt;/PRE&gt;&lt;PRE class=code&gt;&lt;SPAN style="COLOR: green"&gt;//Define string format &lt;BR&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;StringFormat &lt;/SPAN&gt;format1 = &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;StringFormat&lt;/SPAN&gt;(&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;StringFormatFlags&lt;/SPAN&gt;.NoClip);&lt;BR&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;StringFormat &lt;/SPAN&gt;format2 = &lt;SPAN style="COLOR: blue"&gt;new &lt;/SPAN&gt;&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;StringFormat&lt;/SPAN&gt;(format1);&lt;BR&gt;&lt;SPAN style="COLOR: green"&gt;//Draw text string using the text format&lt;BR&gt;&lt;/SPAN&gt;graphics.DrawString(Text, font, &lt;SPAN style="COLOR: rgb(43,145,175)"&gt;Brushes&lt;/SPAN&gt;.Red, (&lt;SPAN style="COLOR: rgb(43,145,175)"&gt;RectangleF&lt;/SPAN&gt;)displayRectangle, format2);&lt;/PRE&gt;&lt;PRE class=code&gt;&lt;B&gt;&lt;FONT face="Trebuchet MS"&gt;Step 8 - Send the bitmap to page output stream in JPEG format&lt;/FONT&gt;&lt;/B&gt;&lt;/PRE&gt;&lt;PRE class=code&gt;Response.ContentType = &lt;SPAN style="COLOR: rgb(163,21,21)"&gt;"image/jpeg"&lt;/SPAN&gt;;&lt;BR&gt;bitmap.Save(Response.OutputStream, &lt;SPAN style="COLOR: rgb(43,145,175)"&gt;ImageFormat&lt;/SPAN&gt;.Jpeg);&lt;/PRE&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;B&gt;&lt;U&gt;Using TextToImageConvertor&lt;/U&gt;&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;TextToImageConvertor is developed as a web page which can be accessed directly by passing the text in he query string.&lt;/P&gt;
&lt;P&gt;To demonstrate the use of this tool, create a webpage with a textbox, a button and an image control. On the click event of the button, set the image URL to the convertor page and pass the text of text box into the query string. In the example code below, I have named my image control as img1 and text box as txtNote.&lt;/P&gt;&lt;PRE class=code&gt;img1.ImageUrl = &lt;SPAN style="COLOR: rgb(163,21,21)"&gt;"default2.aspx?Text=" &lt;/SPAN&gt;+ txtNote.Text;&lt;/PRE&gt;
&lt;P&gt;&lt;A href="http://11011.net/software/vspaste" mce_href="http://11011.net/software/vspaste"&gt;&lt;/A&gt;
&lt;DIV class=wlWriterEditableSmartContent id=scid:0767317B-992E-4b12-91E0-4F059A8CECA8:4037caf6-2b9e-4499-81ae-22b64c199b91 style="PADDING-RIGHT: 0px; DISPLAY: inline; PADDING-LEFT: 0px; PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-TOP: 0px"&gt;Technorati Tags: &lt;A href="http://technorati.com/tags/ASP.net" rel=tag mce_href="http://technorati.com/tags/ASP.net"&gt;ASP.net&lt;/A&gt;,&lt;A href="http://technorati.com/tags/Graphics" rel=tag mce_href="http://technorati.com/tags/Graphics"&gt;Graphics&lt;/A&gt;&lt;/DIV&gt;
&lt;DIV class=wlWriterEditableSmartContent style="PADDING-RIGHT: 0px; DISPLAY: inline; PADDING-LEFT: 0px; PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-TOP: 0px"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;A href="http://www.dotnetkicks.com/kick/?url=http%3a%2f%2fweblogs.asp.net%2fyaneshtyagi%2farchive%2f2008%2f11%2f07%2ftext-to-image-convertor.aspx"&gt;&lt;IMG alt="kick it on DotNetKicks.com" src="http://www.dotnetkicks.com/Services/Images/KickItImageGenerator.ashx?url=http%3a%2f%2fweblogs.asp.net%2fyaneshtyagi%2farchive%2f2008%2f11%2f07%2ftext-to-image-convertor.aspx" border=0&gt;&lt;/A&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6724835" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/Tools/default.aspx">Tools</category><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/Graphics/default.aspx">Graphics</category><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/ASP.NET/default.aspx">ASP.NET</category><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/C_2300_/default.aspx">C#</category></item><item><title>Ajax Control Toolkit - Controls Disabled in Tool Box</title><link>http://weblogs.asp.net/yaneshtyagi/archive/2008/10/27/ajax-control-toolkit-controls-disabled-in-tool-box.aspx</link><pubDate>Mon, 27 Oct 2008 14:49:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:6707139</guid><dc:creator>Yanesh Tyagi</dc:creator><slash:comments>3</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/rsscomments.aspx?PostID=6707139</wfw:commentRss><wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/yaneshtyagi/commentapi.aspx?PostID=6707139</wfw:comment><comments>http://weblogs.asp.net/yaneshtyagi/archive/2008/10/27/ajax-control-toolkit-controls-disabled-in-tool-box.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;Having my PC broken, I had to work on another machine. I downloaded Visual Web Express and Ajax Control Toolkit. I installed the toolkit as described by &lt;A class="" href="http://weblogs.asp.net/nannettethacker/archive/2008/02/07/ajax-control-tookit-installation-in-visual-web-developer.aspx" mce_href="http://weblogs.asp.net/nannettethacker/archive/2008/02/07/ajax-control-tookit-installation-in-visual-web-developer.aspx"&gt;Nannette&lt;/A&gt;. But nothing appeared on my toolbox. Thinking that I might have missed something, I tried to repeat the process. When I was giving the name during the tab creation step, VWD responded by saying that &lt;/P&gt;
&lt;P mce_keep="true"&gt;Tab name 'Ajax Control Toolkit' already exists.&lt;/P&gt;
&lt;P mce_keep="true"&gt;I was surprised to know that the tab has been successfully created but it was not dislayed. Playing around with different options, I clicked &lt;EM&gt;'Show All'&lt;/EM&gt; option. This option comes when you right click on the empty area of general tab. Checking this option showed me a number of tabs which I haven't seen earlier. &lt;/P&gt;
&lt;P mce_keep="true"&gt;This also showed me my 'Ajax Control Toolkit' tab. But all the options (controls) in this tab disabled (grayed out). I had code view of a aspx page opened on the screen. Thinking that these might get active on the design view, I switched to it. But this did not worked. &lt;/P&gt;
&lt;P mce_keep="true"&gt;Then I restart VWD and opened the website again. But still these are grayed out. Finally I shut down the PC calling it a day. Next day, when I opened the project again, all ajax tab were there and all controls were enabled.&lt;/P&gt;
&lt;P mce_keep="true"&gt;So, if you are also facing the same error, do the following.&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;
&lt;DIV mce_keep="true"&gt;Restart Visual Web Express. If it does not work,&lt;/DIV&gt;&lt;/LI&gt;
&lt;LI&gt;
&lt;DIV mce_keep="true"&gt;Restart the Pc.&lt;/DIV&gt;&lt;/LI&gt;&lt;/OL&gt;
&lt;P mce_keep="true"&gt;I also found one more solution somewhere on the net later on. This is described below:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;
&lt;DIV mce_keep="true"&gt;Close VWb and any other express product installed running such as Visual C# EE.&lt;/DIV&gt;&lt;/LI&gt;
&lt;LI&gt;
&lt;DIV mce_keep="true"&gt;Open windows explorer and navigate to the &lt;BR&gt;&lt;EM&gt;'C:\Documents and Settings\&amp;lt;your user name&amp;gt;\Application Data\Microsoft\VWDExpress\9.0'&lt;/EM&gt; &lt;BR&gt;folder. You might have to enable &lt;EM&gt;'Show Hidden Files'&lt;/EM&gt; under the folder options' View tab.&lt;/DIV&gt;&lt;/LI&gt;
&lt;LI&gt;
&lt;DIV mce_keep="true"&gt;Delete any &lt;EM&gt;.pdb&lt;/EM&gt; file, you found in this folder.&lt;/DIV&gt;&lt;/LI&gt;
&lt;LI&gt;
&lt;DIV mce_keep="true"&gt;Start VWD and reinstall the ACT as described here.&lt;/DIV&gt;&lt;/LI&gt;&lt;/OL&gt;
&lt;P mce_keep="true"&gt;By the way, In one of the comments on&amp;nbsp;nannette blog, skain said, &lt;/P&gt;
&lt;P mce_keep="true"&gt;"Am I the only one who thinks it is utterly ridiculous that we're supposed to use a dll from the WebSite project as the main reference for the toolkit? &amp;nbsp;Why isn't this in a separate class library project?"&lt;/P&gt;
&lt;P mce_keep="true"&gt;skain, I also agree with you. I think that there should be some installer package that will do all this on a single click.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6707139" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/yaneshtyagi/archive/tags/Ajax+Control+Toolkit/default.aspx">Ajax Control Toolkit</category></item></channel></rss>