<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/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>Parag's Weblog</title><link>http://blogs.msdn.com/paraga/default.aspx</link><description /><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>Silent passport authentication from web and load test in VSTT</title><link>http://blogs.msdn.com/paraga/archive/2009/07/10/silent-passport-authentication-from-web-and-load-test-in-vstt.aspx</link><pubDate>Fri, 10 Jul 2009 10:20:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9828420</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/paraga/comments/9828420.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=9828420</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=9828420</wfw:comment><description>&lt;BR&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -18.75pt; MARGIN: 0in 0in 0pt 36.75pt; mso-list: l1 level1 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpFirst&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;1.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Open IE and clear all cookie cache.&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -18.75pt; MARGIN: 0in 0in 0pt 36.75pt; mso-list: l1 level1 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;2.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Start fiddler.&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -18.75pt; MARGIN: 0in 0in 0pt 36.75pt; mso-list: l1 level1 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;3.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;FONT face=Calibri&gt;Browse application in IE. &lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -18.75pt; MARGIN: 0in 0in 0pt 36.75pt; mso-list: l1 level1 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;4.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;It will cause redirect to passport login page. &lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -18.75pt; MARGIN: 0in 0in 0pt 36.75pt; mso-list: l1 level1 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;5.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Authenticate.&amp;nbsp;We will land up to home page.&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -18.75pt; MARGIN: 0in 0in 0pt 36.75pt; mso-list: l1 level1 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;6.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Stop fiddler.&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -18.75pt; MARGIN: 0in 0in 0pt 36.75pt; mso-list: l1 level1 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;7.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Examine http traces:&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -19.5pt; MARGIN: 0in 0in 0pt 73.5pt; mso-list: l1 level2 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;a.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Filter out request for CSS, JS, images etc. for ease of reading.&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -19.5pt; MARGIN: 0in 0in 0pt 73.5pt; mso-list: l1 level2 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;b.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Examine POST request made to home page in the trace. Examine cookies collection for this request.&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -19.5pt; MARGIN: 0in 0in 0pt 73.5pt; mso-list: l1 level2 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;c.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;The one’s which are of interest to us is: -&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -0.25in; MARGIN: 0in 0in 0pt 1.75in; mso-list: l0 level1 lfo2; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;B style="mso-bidi-font-weight: normal"&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;i.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/B&gt;&lt;FONT face=Calibri&gt;&lt;B&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;MSPP_RPSAuth&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; MARGIN: 0in 0in 12pt 1.5in; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;FONT face=Calibri&gt;&lt;B&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;ii.&lt;/SPAN&gt;&lt;/B&gt;&lt;B&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 7pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/B&gt;&lt;B&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;MSPP_RPSSecAuth&lt;/SPAN&gt;&lt;/B&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -18.75pt; MARGIN: 0in 0in 12pt 36.75pt; mso-list: l1 level1 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;8.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Above cookies uniquely identify a given logged in user. For that browser session all subsequent requests will use these cookies for authentication, failing which, will redirect user back in login page. Session persists for 24 hours from the time of login. &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -18.75pt; MARGIN: 0in 0in 12pt 36.75pt; mso-list: l1 level1 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;9.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Next step is to create web test. &lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -18.75pt; MARGIN: 0in 0in 0pt 36.75pt; mso-list: l1 level1 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;10.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Create a web test and add a request for same home page. We will now modify headers &lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;collection for this request.&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -19.5pt; MARGIN: 0in 0in 0pt 73.5pt; mso-list: l1 level2 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;a.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Right click on request and “Add Header”.&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -19.5pt; MARGIN: 0in 0in 0pt 73.5pt; mso-list: l1 level2 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpLast&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-size: 8.0pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;b.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Add above cookies in cookie collection with their respective values. For example, &lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 8pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; MARGIN: 0in 0in 12pt" class=MsoNormal&gt;&lt;FONT size=3&gt;&lt;FONT face=Calibri&gt;&lt;SPAN style="COLOR: #984806; mso-themecolor: accent6; mso-themeshade: 128; mso-bidi-font-size: 9.0pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;Cookie= MSPP_RPSAuth=&lt;B style="mso-bidi-font-weight: normal"&gt;&amp;lt;pick value from trace&amp;gt;&lt;/B&gt;; MSPP_RPSSecAuth=&lt;B style="mso-bidi-font-weight: normal"&gt;&amp;lt;pick value from trace&amp;gt;;&lt;/B&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #984806; FONT-SIZE: 8pt; mso-themecolor: accent6; mso-themeshade: 128; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -18.75pt; MARGIN: 0in 0in 0pt 36.75pt; mso-list: l1 level1 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpFirst&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;11.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;FONT face=Calibri&gt;We are done!! Executing this web test will directly take you to home page by impersonating the user.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; TEXT-INDENT: -18.75pt; MARGIN: 0in 0in 10pt 36.75pt; mso-list: l1 level1 lfo1; mso-add-space: auto" class=MsoListParagraphCxSpLast&gt;&lt;SPAN style="FONT-FAMILY: 'Times New Roman','serif'; COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-fareast-font-family: 'Times New Roman'"&gt;&lt;SPAN style="mso-list: Ignore"&gt;12.&lt;SPAN style="FONT: 7pt 'Times New Roman'"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;FONT face=Calibri&gt;Above web test can be used in load test as well.&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; MARGIN: 0in 0in 10pt" class=MsoNormal&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;o:p&gt;&lt;FONT face=Calibri&gt;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="LINE-HEIGHT: normal; MARGIN: 0in 0in 10pt" class=MsoNormal&gt;&lt;SPAN style="COLOR: #4c4c4c; FONT-SIZE: 12pt; mso-bidi-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-bidi-theme-font: minor-latin"&gt;&lt;FONT face=Calibri&gt;Hope that helps,&lt;BR&gt;--Parag&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9828420" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/VSTS/default.aspx">VSTS</category></item><item><title>Troubleshooting Web Application Performance</title><link>http://blogs.msdn.com/paraga/archive/2009/07/09/troubleshooting-web-application-performance.aspx</link><pubDate>Thu, 09 Jul 2009 20:14:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9827223</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/paraga/comments/9827223.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=9827223</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=9827223</wfw:comment><description>&lt;P mce_keep="true"&gt;&lt;BR&gt;Every app is different and every server is different. It's only through extensive understanding of the application that decision can be made to improve its performance. There are no specific set of rules we can define that will ensure app will run with great performance on a given server. Only thing we can do is to come up with a framework/checklist that we might want to review.&lt;BR&gt;&lt;/P&gt;
&lt;P&gt;&lt;BR&gt;So let's start by defining key &lt;I&gt;performance pillars&lt;/I&gt;: &lt;BR&gt;&lt;/P&gt;
&lt;P&gt;&lt;B&gt;&lt;U&gt;End user&lt;/U&gt;&lt;/B&gt; - defines performance of the site as viewed by the end user. For example, do customers notice that how long it takes to render, what's the speed, is it fast enough etc.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;B&gt;&lt;U&gt;Throughput&lt;/U&gt;&lt;/B&gt; - measuring per second values (Request, bytes and connections) which apply at several levels like, Farm, Server, Website, Application Pool, and even URL users are browsing.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;B&gt;&lt;U&gt;Capacity&lt;/U&gt;&lt;/B&gt; - How much we can support in terms of Users, Connections, Throughput, and Content etc.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;B&gt;&lt;U&gt;Scaling&lt;/U&gt;&lt;/B&gt; - a way to fix performance problems.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;BR&gt;After we have listed out key performance pillars, we need to measure them. &lt;/P&gt;
&lt;P&gt;&lt;B&gt;&lt;I&gt;&lt;BR&gt;&lt;U&gt;Measuring End user&lt;BR&gt;&lt;/U&gt;&lt;/I&gt;&lt;/B&gt;Use (or may be test) the site as end users would use. What is their connection speed, check out for client or proxy caching happening, what browsers (with versions) are used to browse the site etc. One thing we need to keep in mind that application is developed and tested in high speed LAN and conditions will not be same when deployed on internet where still most of the users are running on modem and low speed connections. So customer experience and your experience will be different. &lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;BR&gt;But the challenge is we really can't get all our customers so best we can do is to bucket-ize the customers and put them into groups like how much % of them are modem users, how many are on high speed connections, how many have direct T1 lines etc. Now the question is, how do I find those buckets? What are the best tools to capture and report such data? One of the tools is &lt;A href="http://www.iis.net/default.aspx?tabid=2&amp;amp;subtabid=29#LogParser" mce_href="http://www.iis.net/default.aspx?tabid=2&amp;amp;subtabid=29#LogParser"&gt;Log Parser&lt;/A&gt;. &lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;BR&gt;It's an extensive tool that will help us to analyze IIS performance by parsing IIS logs. We will also look out for different type of browsers being used and how long these request takes. This tool can be executed through command line and it expects a query (almost similar to SQL syntax) for performing heuristics on a given log.&lt;BR&gt;&lt;BR&gt;For example, we will write a script that will return type of browsers used to browse the website.&lt;BR&gt;%logparserinstalldir%&amp;gt; logparser.exe GetBrowsers.sql&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;I&gt;&lt;U&gt;&lt;BR&gt;GetBrowser.sql&lt;BR&gt;&lt;/U&gt;&lt;/I&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 10pt" class=MsoNormal&gt;&lt;SPAN style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Arial','sans-serif'; COLOR: #17365d; FONT-SIZE: 10pt; mso-themecolor: text2; mso-themeshade: 191"&gt;SELECT TOP 10 &lt;BR&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;to_int(null(100.0,propcount(*))) as Percent&lt;BR&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Count(*) as TotalHits&lt;BR&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;cs(user-Agent) as Browser&lt;BR&gt;FROM&amp;nbsp; &lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;%logfile%&lt;BR&gt;GROUP BY Browser&lt;BR&gt;ORDER BY TotalHits desc&lt;/SPAN&gt;&lt;SPAN style="COLOR: #17365d; mso-themecolor: text2; mso-themeshade: 191"&gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;
&lt;TABLE border=0 cellSpacing=0 cellPadding=0&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=85&gt;
&lt;P&gt;Percent&lt;/P&gt;&lt;/TD&gt;
&lt;TD vAlign=top width=78&gt;
&lt;P&gt;Total Hits&lt;/P&gt;&lt;/TD&gt;
&lt;TD vAlign=top width=126&gt;
&lt;P&gt;Browser&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=85&gt;
&lt;P&gt;15&lt;/P&gt;&lt;/TD&gt;
&lt;TD vAlign=top width=78&gt;
&lt;P&gt;771&lt;/P&gt;&lt;/TD&gt;
&lt;TD vAlign=top width=126&gt;
&lt;P&gt;MSIE 6.0&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=85&gt;
&lt;P&gt;50&lt;/P&gt;&lt;/TD&gt;
&lt;TD vAlign=top width=78&gt;
&lt;P&gt;565&lt;/P&gt;&lt;/TD&gt;
&lt;TD vAlign=top width=126&gt;
&lt;P&gt;MSIE 7.0&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD vAlign=top width=85&gt;
&lt;P&gt;10&lt;/P&gt;&lt;/TD&gt;
&lt;TD vAlign=top width=78&gt;
&lt;P&gt;109&lt;/P&gt;&lt;/TD&gt;
&lt;TD vAlign=top width=126&gt;
&lt;P&gt;Some other browser ...&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/P&gt;
&lt;P&gt;&lt;BR&gt;Why is that important to know about browser? It is because each browser has a different caching technique, rendering mechanism etc. Accordingly we may want to change output HTML along with header for better performance.&lt;BR&gt;&lt;BR&gt;We can start identifying important page(s) that users could be hitting and what is the average, maximum, minimum and hit count for such page(s). &lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 10pt" class=MsoNormal&gt;&lt;SPAN style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Arial','sans-serif'; COLOR: #17365d; FONT-SIZE: 10pt; mso-themecolor: text2; mso-themeshade: 191"&gt;SELECT&amp;nbsp;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; to_lowercase(cs-url-stem) as URL&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; AVG(time-taken)&amp;nbsp; as AvgTime&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MIN (time-taken)&amp;nbsp; as MinTime&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; MAX(time-taken) as MaxTime&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; count(*)&amp;nbsp; as HitCount&lt;BR&gt;FROM&amp;nbsp;&amp;nbsp; %logfile%&lt;BR&gt;WHERE&amp;nbsp;URL&amp;nbsp; = ‘/default.asp'&lt;BR&gt;GROUP BY URL&lt;/SPAN&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;BR&gt;Script below will list out clients connected (requesting something) and we will try to identify slow connection(s).&lt;BR&gt;&lt;BR&gt;&lt;/P&gt;
&lt;P style="MARGIN: 0in 0in 10pt" class=MsoNormal&gt;&lt;SPAN style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Arial','sans-serif'; COLOR: #17365d; FONT-SIZE: 10pt; mso-themecolor: text2; mso-themeshade: 191"&gt;SELECT c-ip as Client&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Avg(sc-bytes)&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Avg(time-taken)&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; to_int ( mul ( div (to_real (sc_bytes), case avg(time-taken) when 0 then 1 else avg(time-taken)), 1000 ) ) as BytesPerSecond&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Count(*) as Hits&lt;BR&gt;FROM&amp;nbsp;&amp;nbsp;&amp;nbsp;%logfile%&lt;BR&gt;WHERE&amp;nbsp;sc-bytes&amp;nbsp; &amp;gt;&amp;nbsp; 1 and time-taken &amp;gt; 1000 [ where condition to ensure that we are taking connections that did not get dropped. 1000 is measured in milliseconds which means 1 second]&lt;BR&gt;GROUP BY&amp;nbsp; Client, cs(user-Agent) &lt;BR&gt;HAVING&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; hits &amp;gt; 1&lt;BR&gt;&lt;/SPAN&gt;&lt;BR&gt;By running above query we can find out&amp;nbsp;slowest client&amp;nbsp;. It could be possible that it is one of the most important clients. This does not mean that server is performing badly nor has a fast connection to internet rather it seems that client is on slow connection may be modem. It gives us few points to discuss. For example, can we do something to reduce the payload (IIS compression is one way to achieve it) so that app works for slow clients as well? &lt;BR&gt;&lt;B&gt;&lt;I&gt;&lt;BR&gt;&lt;U&gt;Measuring Throughput&lt;BR&gt;&lt;/U&gt;&lt;/I&gt;&lt;/B&gt;Performance monitor is the key way to learn what the throughput is. However it does only at server and site level. But we can use log parser for other levels for example, for URL, we can use log parser to know URL request per second/hour/minute and no of bytes transferred to different clients as we see in above examples. &lt;BR&gt;ETW (Event tracing for windows) is yet another excellent tool to understand performance, throughput of the server and other issues through extensive logging mechanism. It traces each and every call within the server till the time request reaches to server (HTTP.SYS in case of win 2k3) and served back to the client, what all operations are involved for that individual request. I would like to take an example, where ETW tracing proved to be useful in diagnosing performance issues. After publishing a website to another server, very first request to any aspx/asp page was taking huge amount of time. Running an ETW trace on that server resulted in a log file upon investigating which it was found that first request was taking long time because of ISAPI filter installed on top of IIS was taking long time to load hence blocking all other operations.&lt;BR&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Now we can understand &amp;amp; define performance and know some ways to measure it we will move on to how we can improve performance of a given web application. Again, there is no defined way to improve the performance. It includes making guesses, see if they work, if they do, celebrate and make another guess. If they don't, undo it and make another guess.&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;&lt;/P&gt;
&lt;P&gt;&lt;U&gt;&lt;B&gt;&lt;I&gt;Improving&lt;/I&gt;&lt;/B&gt; &lt;B&gt;&lt;I&gt;end user performance&lt;BR&gt;&lt;/I&gt;&lt;/B&gt;&lt;/U&gt;In the internet scenario we can define key issues: -&lt;/P&gt;
&lt;P&gt;&lt;I&gt;&lt;U&gt;Download time&lt;/U&gt;&lt;/I&gt;&lt;BR&gt;According to a survey, still more than 50% of internet users still have narrow band connections let's say, modem. So if testing and verification is done in a high speed LAN environment, we cannot understand and foresee customer problems that might be running on narrow band connection.&lt;BR&gt;&lt;/P&gt;
&lt;P&gt;So specific items we can look at to address such key issues are: -&lt;BR&gt;&lt;/P&gt;
&lt;UL class=unIndentedList&gt;
&lt;LI&gt;Download size is performance key driver on low band connections. How do we fix download size? One of the best ways is to enable IIS compression. &lt;/LI&gt;
&lt;LI&gt;Try to split up the helper content (style sheets, client side scripts). For example, if you don't need a specific JS function/Style sheet for a page currently being requested, do not download it!! Download it only when you need it. &lt;/LI&gt;
&lt;LI&gt;Do not make copies of things (script code, style sheets etc.) that are being downloaded and have duplication in website. Let's understand it with an example,&lt;BR&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;B&gt;Bad CSS (Replication of data)&lt;/B&gt;&lt;BR&gt;.article-ByLine&amp;nbsp; { font-family: Tahoma,sans-serif; font-size: 9.5pt; font-style: normal; line-height: normal; font-weight: normal; color: #000000}&lt;BR&gt;.article-Caption {font-family: Tahoma,sans-serif; font-size: 8pt; font-style: normal; line-height: normal; font-weight: normal; color: #000000}&lt;BR&gt;.article-Headline { font-family: Tahoma,sans-serif; font-size: 14pt; font-style: normal; line-height: normal; font-weight: bold; color: #000000} &lt;BR&gt;&lt;BR&gt;In above example, highlighted text is same for each definition except font-size. It results, in increased payload. Same CSS can be represented as: -&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;BODY {font-family: Tahoma,sans-serif; font-style: normal; line-height: normal; font-weight: normal; color: #000000}&lt;BR&gt;.article-ByLine {font-size: 9.5pt;}&lt;BR&gt;.article-Caption { font-size: 8pt}&lt;BR&gt;.article-Headline {font-size: 14pt;font-weight:bold} &lt;BR&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Set HTTP expire header for all images and for HTML so proxy servers &amp;amp; browsers make fewer calls to web serve. For more information, visit &lt;A href="http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/0fc16fe7-be45-4033-a5aa-d7fda3c993ff.mspx?mfr=true" mce_href="http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/0fc16fe7-be45-4033-a5aa-d7fda3c993ff.mspx?mfr=true"&gt;Content Expiration&lt;/A&gt;. &lt;/LI&gt;
&lt;LI&gt;Use SSL certificates only when needed and only for content that requires security. Because SSL uses complex encryption that consumes considerable processor resources, it takes much longer to retrieve and send data from SSL-enabled directories. Also, keep these pages free of other elements that consume resources, such as images. &lt;/LI&gt;
&lt;LI&gt;Another thing to verify is "connection=keep-alive" state for each TCP connection. If it is turned off every file requires a new TCP connection which is not good for a slow connection.&lt;/LI&gt;
&lt;LI&gt;Set expiration dates on files - When customer returns to a web page, IE already has most of the files for the page in its cache, but it does not use these files if the expiration dates are in the past. Instead, IE sends a GET request to the server for the file, indicating the date of the file in the cache. If the file has not changed, the server sends a Not Modified message. This GET/Not-Modified sequence costs the client a roundtrip. &lt;/LI&gt;
&lt;LI&gt;Identify slow loading files which will provide clues what needs to be improved. Causes of very long load times can include server capacity issues, network congestion. This data can be collected by running log parser on IIS logs or by using &lt;A href="http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/592e2b3e-02d5-4b37-b0dc-a728e0636974.mspx?mfr=true" mce_href="http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/592e2b3e-02d5-4b37-b0dc-a728e0636974.mspx?mfr=true"&gt;ETW&lt;/A&gt; tracing mechanism.&lt;/LI&gt;
&lt;LI&gt;Files often contain TABS, spaces, newlines, and comments contributing some % of page size. Try removing those.&lt;BR&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;I&gt;&lt;U&gt;Hardware Resources &lt;/U&gt;&lt;/I&gt;&lt;BR&gt;If CPU is the issue, think about caching so that we don't compute so often. Is HTTP compression causing this to happen etc.?&lt;BR&gt;&lt;/P&gt;
&lt;P&gt;If memory is an issue, check if we are caching too much, how many copies of same data we are caching etc. So there is a tradeoff, which is hitting you much, CPU or Memory and take the judgment accordingly. You can monitor memory by making use of existing performance monitor counters. Here are few of them: -&lt;BR&gt;&lt;/P&gt;
&lt;UL class=unIndentedList&gt;
&lt;LI&gt;Monitoring Available System Memory - Memory\Available Bytes, &lt;/LI&gt;
&lt;LI&gt;Monitoring Paging - Memory\Page Faults/sec, Memory\Pages Input/sec, Memory\Page Reads/sec, Memory\Transition Faults/sec (&lt;I&gt;If these numbers are low, server is responding to requests quickly. If these numbers are high, investigate whether we have dedicated too much memory to the caches, leaving too little memory for the rest of the system. If reducing cache sizes does not improve system performance, we might need to increase the amount of RAM on server&lt;/I&gt;)&lt;/LI&gt;
&lt;LI&gt;To know more about IIS performance counters, visit &lt;A href="http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/0a6c9f07-a70c-4c3d-b93d-5dfef593c744.mspx?mfr=true" mce_href="http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/0a6c9f07-a70c-4c3d-b93d-5dfef593c744.mspx?mfr=true"&gt;http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/0a6c9f07-a70c-4c3d-b93d-5dfef593c744.mspx?mfr=true&lt;/A&gt;.&lt;BR&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;If disk is slow determine who is causing file access. Best tool available for this purpose is &lt;A href="http://technet.microsoft.com/en-us/sysinternals/bb896642.aspx" mce_href="http://technet.microsoft.com/en-us/sysinternals/bb896642.aspx"&gt;Filemon&lt;/A&gt;. For example, it could be possible that web site logging is turned on causing several file I/O's hence degrading the performance.&lt;BR&gt;&lt;/P&gt;
&lt;P&gt;Till now we have discussed key performance pillars, how we can measure them and ways to fix them.&lt;/P&gt;
&lt;P&gt;Performance issues can be difficult to troubleshoot and often take a long time to determine the root cause &amp;amp; resolve. This process can be less painful if we collect good data and then use that information further to solve the issue. So how can we collect good data? By asking as many questions we can. For example, &lt;BR&gt;&lt;/P&gt;
&lt;UL class=unIndentedList&gt;
&lt;LI&gt;When the problem did started happening? Was there any change or update on the server prior to the problem? &lt;/LI&gt;
&lt;LI&gt;What are the different symptoms? Is there one or more error messages shown? &lt;/LI&gt;
&lt;LI&gt;Is there a High CPU on the server at the time of the problem? &lt;/LI&gt;
&lt;LI&gt;Is the worker process consuming high memory (Approx 500-600MB+) at the time of the problem? &lt;/LI&gt;
&lt;LI&gt;What are the technologies (including third-party) involved? &lt;/LI&gt;
&lt;LI&gt;Are there any COM/COM+ components being used? If so, are they STA or MTA? &lt;/LI&gt;
&lt;LI&gt;Does the problem happen at a specific interval? &lt;/LI&gt;
&lt;LI&gt;Do ASPX/ASP/ HTML pages in the same/different Applications on the same server work fine? &lt;/LI&gt;
&lt;LI&gt;Is the issue specific to any pages in the application or only to some pages? &lt;/LI&gt;
&lt;LI&gt;Does a simple hello world aspx page work fine? &lt;/LI&gt;
&lt;LI&gt;What is the architecture of the application? &lt;/LI&gt;
&lt;LI&gt;Is Data Access involved? If so, does the issue happen with any page connecting to a particular database? &lt;/LI&gt;
&lt;LI&gt;If Data Access is involved, does any page that does not do data access work fine? &lt;/LI&gt;
&lt;LI&gt;What is the application workflow with respect to the current problem? &lt;/LI&gt;
&lt;LI&gt;What are the steps to repro the problem? &lt;/LI&gt;
&lt;LI&gt;Is problem reproducible in test environment? &lt;BR&gt;&lt;BR&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;Once we have gathered the above data I am pretty sure we will have a good idea on where to focus. Based on symptoms and data we need to decide if the problem is on client side, server side, database/other tier or combination of one or more of these.&amp;nbsp;There are several tools available that can now assist us to find root cause. &lt;BR&gt;&lt;/P&gt;
&lt;UL class=unIndentedList&gt;
&lt;LI&gt;Network monitoring tools (netmon) can be used to examine network related problems, page rendering delays etc.&lt;/LI&gt;
&lt;LI&gt;File monitoring (filemon) and Registry monitoring (regmon) tool can help us in identifying file system and registry based access issues.&lt;/LI&gt;
&lt;LI&gt;ETW (Event tracing for windows) which can be used to trace internal IIS/kernel (HTTP.SYS in case of win2k3) events and pinpoint web bottlenecks on the server and often determine where to tune server for improved performance.&lt;/LI&gt;
&lt;LI&gt;WinDbg/CorDbg - Used for advanced debugging by analyzing memory dumps on production server without even going through source code.&lt;BR&gt;&lt;BR&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;I hope this article gets you going to start troubleshooting and analyzing performance issues for a given website hosted on IIS.&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;Bye for now,&lt;BR&gt;--Parag&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=9827223" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/Performance/default.aspx">Performance</category></item><item><title>Creating EVT &amp;amp;amp; IVT's using VS 2005 Test Suite</title><link>http://blogs.msdn.com/paraga/archive/2007/04/28/creating-evt-ivt-s-using-vs-2005-test-suite.aspx</link><pubDate>Sat, 28 Apr 2007 18:08:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:2313130</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/paraga/comments/2313130.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=2313130</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=2313130</wfw:comment><description>&lt;P&gt;So i am back after a long break. Just to give you a little bit of background i recently shifted from Microsoft PSS (where i used to support ASP.NET and IIS) to Micorosft IT Division as a developer where we create solutions&amp;nbsp;for our valuable Microsoft&amp;nbsp;Partners.&amp;nbsp;So let's get started now:&lt;/P&gt;
&lt;P&gt;So you must be thinking what these terms EVT &amp;amp; IVT means. Since i am&amp;nbsp;in application development now i will also be&amp;nbsp;sharing best practices revolving around application developement, deployment etc.. So&amp;nbsp;the very&amp;nbsp;first step before deploying any application is to run EVT (Environment Verification Test) and IVT (Installation Verification Test).&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;EVT:&lt;/STRONG&gt; It will basically consists of tests to verify the environment (both hardware and software) under which&amp;nbsp;your application is subjected to run. For example, knowing hardware requirement,&amp;nbsp;HDD space check, OS check, IIS, SQL Server etc.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;IVT:&lt;/STRONG&gt; It would consists of tests to verify whether application successfully installed or not. For example, various configurations for proper functioning of the application are correct, required virtual directories exists on website, required DB's exists on SQL server, web services are getting back the results etc..&lt;/P&gt;
&lt;P&gt;Advantage&amp;nbsp;is obvious i.e. after running EVT's and IVT's and correcting the faults encountered during the course we are sure application will run fine where it is deployed and no more obvious surprises on production environment.&amp;nbsp;EVT's and IVT's reminds me of TDD (Test Driven Development) and what can be better then creating these set of checks in form of test cases by leveraging VS 2005 Team Suite for Tester. Earlier i used Nunit and can be downloaded from sourceforge.net. Best&amp;nbsp;part is we can still&amp;nbsp;consume the test assembly&amp;nbsp;generated by VS 2005&amp;nbsp;Test Suite in Nunit if we dont want to install the complete suite on the server where checks will be performed.&lt;/P&gt;
&lt;P&gt;Hope that helps&amp;nbsp;... &lt;IMG alt=Wave src="http://us.i1.yimg.com/us.yimg.com/i/mesg/emoticons7/103.gif" mce_src="http://us.i1.yimg.com/us.yimg.com/i/mesg/emoticons7/103.gif"&gt;&lt;BR&gt;--Parag&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&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=2313130" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/Performance/default.aspx">Performance</category></item><item><title>Getting CryptographicException exception "Padding is invalid and cannot be removed" after Migrating to ASP.NET 2.0</title><link>http://blogs.msdn.com/paraga/archive/2006/07/03/655081.aspx</link><pubDate>Mon, 03 Jul 2006 10:17:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:655081</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/paraga/comments/655081.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=655081</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=655081</wfw:comment><description>&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Verdana"&gt;Problem Description&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Verdana"&gt;=============&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;One of my colleague migrated his asp.net 1.1 application to asp.net 2.0. It worked fine for some time and soon after it is deployed it started giving intermittent security exception below:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;Event code: 3005&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Event&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;An unhandled exception has occurred.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Event time: 6/22/2006 10:58:04 AM&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Event time (UTC): 6/22/2006 2:58:04 PM&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Event ID: 8f96fc240df941e98447cb4f46b8bc61&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Event sequence: 26440&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Event occurrence: 1321&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Event detail code: 0&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Application information:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Application domain: /LM/W3SVC/&amp;lt;remoevd&amp;gt;/Root-1-127954582343593239&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Trust level: Full&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Application Virtual Path: /&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Application Path: &amp;lt;removed&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Machine name: &amp;lt;removed&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Process information:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Process ID: 9364&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Process name: w3wp.exe&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Account name: &amp;lt;removed&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Exception information:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Exception type: CryptographicException&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Exception Msg:&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/SPAN&gt;Padding is invalid and cannot be removed.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Request information:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Request URL: https://.../WebResource.axd?d=UphM0djXQAbNBS80WyI_2Q2&amp;amp;t=632863388699082620&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Request path: /WebResource.axd&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;User host address: &amp;lt;removed&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;User:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Is authenticated: False&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Authentication Type:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Thread account name: &amp;lt;removed&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Thread information:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Thread ID: 12&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Thread account name: &amp;lt;removed&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Is impersonating: False&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;Stack trace: at System.Security.Cryptography.RijndaelManagedTransform.DecryptData(Byte[] inputBuffer, Int32 inputOffset, Int32 inputCount, Byte[]&amp;amp; outputBuffer, Int32 outputOffset, PaddingMode paddingMode, Boolean fLast)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;at System.Security.Cryptography.RijndaelManagedTransform.TransformFinalBlock(Byte[] inputBuffer, Int32 inputOffset, Int32 inputCount)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;at System.Security.Cryptography.CryptoStream.FlushFinalBlock()&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;at System.Web.Configuration.MachineKeySection.EncryptOrDecryptData(Boolean fEncrypt, Byte[] buf, Byte[] modifier, Int32 start, Int32 length, Boolean useValidationSymAlgo)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;at System.Web.UI.Page.DecryptString(String s)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;at System.Web.Handlers.AssemblyResourceLoader.System.Web.IHttpHandler.ProcessRequest(HttpContext context)&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 9pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 9pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean&amp;amp; completedSynchronously)&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Verdana"&gt;Resolution&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Verdana"&gt;=======&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Application is deployed on a web farm. Viewstate is disabled completely. The same application is working fine under a web farm in 1.1 version. Issue happens only when it is run under 2.0. &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;The reason it is not working because &amp;lt;machineKey&amp;gt; for this application on all the servers connected to a web farm is not the same. My colleague turned it off because he was not using viewstate at all and that worked fine in 1.1. Then why it is failing on 2.0 and that too when Webresource.axd file is requested. The reason being is data to be sent to server along with query string parameter which looks like some sought of hash value uses &amp;lt;machineKey&amp;gt; for encryption &amp;amp; decryption. As a result, it requires &amp;lt;machineKey&amp;gt; to be same for that application on all the servers.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;To be sure, we isolated the issue by running testing the app. on a single server. By doing that, we did not get the issue.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;More information on Webresource.axd can be found at: &lt;A href="http://support.microsoft.com/kb/910442/en-us"&gt;http://support.microsoft.com/kb/910442/en-us&lt;/A&gt;&lt;/SPAN&gt; &lt;/P&gt;
&lt;P&gt;HTH,&lt;/P&gt;
&lt;P&gt;Parag&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=655081" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/ASP.NET+2.0/default.aspx">ASP.NET 2.0</category></item><item><title>ASP.NET 2.0 - Errors while re-directing user to an error page after the exception is thrown from COM Port</title><link>http://blogs.msdn.com/paraga/archive/2006/05/16/599086.aspx</link><pubDate>Tue, 16 May 2006 20:24:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:599086</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/paraga/comments/599086.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=599086</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=599086</wfw:comment><description>&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;Abstract&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;=======&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;There&amp;nbsp;is an ASP.NET 2.0 application inside of which&amp;nbsp;i connect to serial COM port by using the classes present in System.IO.Port namespace (&lt;A href="http://msdn2.microsoft.com/en-us/system.io.ports.serialport.aspx"&gt;http://msdn2.microsoft.com/en-us/system.io.ports.serialport.aspx&lt;/A&gt;).&amp;nbsp;I am able to connect to COM port, fetch the data and trap the exceptions when the device is disconnected, successfully. When some device is disconnected from the COM port&amp;nbsp;I want the&amp;nbsp;user to redirect to&amp;nbsp;an error page&amp;nbsp;within the exception handler code. In order to do this, using Response.Redirect/ Server.Transfer will give me the error message below: -&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;"&lt;I style="mso-bidi-font-style: normal"&gt;Response is not available in this context&lt;/I&gt;"&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;Cause&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;=====&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;This is an expected behavior because HTTP Context is&amp;nbsp;not available in&amp;nbsp;at that point of time. As a result,&amp;nbsp;we cannot use any of the classes present inside http context i.e. response, request, session etc. It is not available&amp;nbsp;because exception handler event is fired not due to page post back, but because of external change event. As far as page life cycle goes http context is built when page&amp;nbsp;is requested and gets destroyed after the page is served/rendered.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;To get more understanding on the page life cycle, please visit the following link: -&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;A href="http://msdn2.microsoft.com/en-us/library/ms178472.aspx"&gt;http://msdn2.microsoft.com/en-us/library/ms178472.aspx&lt;/A&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;&lt;FONT face=Verdana size=2&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/o:p&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;Resolution/ Workaround&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;==================&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;FONT face=Verdana size=2&gt;I&amp;nbsp;created a static boolean variable at the page level and initialized it to false. When the exception will occur,&amp;nbsp;I will simply set the variable to true (in the exception handler code). Also,&amp;nbsp;I will keep refreshing the page lets say, after every 5 seconds and keep checking for its value in the page load. If value comes out to be true, we will simply redirect user to the error page.&lt;/FONT&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=599086" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/ASP.NET+2.0/default.aspx">ASP.NET 2.0</category></item><item><title>Setting Server.ScriptTimeout programatically in ASP.NET not taking into effect</title><link>http://blogs.msdn.com/paraga/archive/2006/05/08/592417.aspx</link><pubDate>Mon, 08 May 2006 17:14:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:592417</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/paraga/comments/592417.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=592417</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=592417</wfw:comment><description>&lt;P&gt;&lt;FONT face=Verdana size=2&gt;The reason behind it was that debug attribute was set to true inside web.config. If debug attribute is set to true, then batch compilation is diasbled &amp;lt;httpRuntime executionTimeout /&amp;gt; or calls to Server.ScriptTimeout is ignored.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;To confirm, set the debug attribute to true and then request any aspx page. After that browse to&amp;nbsp;Temporary ASP.NET files folder and locate application directory. Inside&amp;nbsp;that directory locate the .cs&amp;nbsp;or .vb file dynamically&amp;nbsp;generated for&amp;nbsp;the requested aspx page. Open that up and you will find &lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;this.Server.ScriptTimeout = 30000000 by default even if you set Server.ScriptTimeout value in the Page Load.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;For more information, please visit the url - &lt;A href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnaspp/html/monitor_perf.asp"&gt;http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnaspp/html/monitor_perf.asp&lt;/A&gt;&lt;BR&gt;&lt;/FONT&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=592417" width="1" height="1"&gt;</description></item><item><title>ASP.NET - Getting 0 value for Request/Sec and Total Req. in performance monitor</title><link>http://blogs.msdn.com/paraga/archive/2006/04/02/566805.aspx</link><pubDate>Sun, 02 Apr 2006 13:15:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:566805</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/paraga/comments/566805.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=566805</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=566805</wfw:comment><description>&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Things to check: -&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;OL style="MARGIN-TOP: 0in" type=1&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Check the following registry key &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;FONT color=#006400&gt;HKLM\SYSTEM\CurrentControlSet\Services\ASP.NET_1.1.4322\Performance\Library&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt; and make sure that it is pointing to correct version of aspnet_isapi.dll.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Shutdown IIS and remote registry services. &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Run commands &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;OL style="MARGIN-TOP: 0in" type=a&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list 1.0in; mso-list: l0 level2 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;unlodctr ASP.NET_1.1.4322&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list 1.0in; mso-list: l0 level2 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;unlodctr ASP.NET&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;/OL&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Then from %Framework% folder, run the following commands: -&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;OL style="MARGIN-TOP: 0in" type=a&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list 1.0in; mso-list: l0 level2 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;lodctr aspnet_perf.ini&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list 1.0in; mso-list: l0 level2 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;unlodctr aspnet_perf2.ini&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;/OL&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;After that restart IIS and remote registry services.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Check whether the following key exists, &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;FONT color=#006400&gt;HKLM\SYSTEM\CurrentControlSet\Services\ASP.NET_1.1.4322\Names&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;If the machine is a Domain Controller, we should have IWAM account instead of ASPNET (NETWORK SERVICE) account in the permissions list for the above registry keys.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;If that still doesn’t resolve the issue then we might be loosing on the required permissions. Worker process identity should have the effective permissions given below on the following registry key &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;FONT color=#006400&gt;HKLM\SYSTEM\CurrentControlSet\Services\ASP.NET_1.1.4322\Names&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;/OL&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt 0.25in"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;OL style="MARGIN-TOP: 0in" type=1 start=8&gt;
&lt;OL style="MARGIN-TOP: 0in" type=a&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list 1.0in; mso-list: l0 level2 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Query Value&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list 1.0in; mso-list: l0 level2 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Set Value&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list 1.0in; mso-list: l0 level2 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Create Subkey&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list 1.0in; mso-list: l0 level2 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Enumerate Subkeys&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list 1.0in; mso-list: l0 level2 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Notify&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list 1.0in; mso-list: l0 level2 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Read Control&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;/OL&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Hope that helps!!!&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Parag&lt;/SPAN&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=566805" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/Support+Cases/default.aspx">Support Cases</category></item><item><title>Why i am getting VBScript runtime (0x800A000D) Type mismatch: 'Session' on ASP page ?</title><link>http://blogs.msdn.com/paraga/archive/2006/03/16/553073.aspx</link><pubDate>Thu, 16 Mar 2006 20:26:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:553073</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/paraga/comments/553073.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=553073</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=553073</wfw:comment><description>&lt;P&gt;&lt;FONT face=Verdana size=2&gt;There could be two reasons: -&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;1. Directory under which ASP page resides is not marked as an application. In other words, its not a *virtual* directory.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;2. *Enable Session State* option is disabled either on the virtual directory level or one level up on the&amp;nbsp;root website. Path to this setting is: Right click Vdir or Website -&amp;gt; Choose Properties -&amp;gt; Virtual Directory tab -&amp;gt; Configuration -&amp;gt; Options Tab.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=553073" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/Internet+Information+Server+_2800_IIS_2900_/default.aspx">Internet Information Server (IIS)</category></item><item><title>Few Things to take care while designing custom Composite Controls</title><link>http://blogs.msdn.com/paraga/archive/2006/03/11/549407.aspx</link><pubDate>Sat, 11 Mar 2006 15:22:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:549407</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>1</slash:comments><comments>http://blogs.msdn.com/paraga/comments/549407.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=549407</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=549407</wfw:comment><description>&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;I style="mso-bidi-font-style: normal"&gt;&lt;U&gt;&lt;SPAN style="COLOR: green; FONT-FAMILY: 'Book Antiqua'; mso-bidi-font-size: 11.0pt"&gt;&lt;FONT size=4&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/U&gt;&lt;/I&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;I style="mso-bidi-font-style: normal"&gt;&lt;U&gt;&lt;SPAN style="COLOR: green; FONT-FAMILY: 'Book Antiqua'; mso-bidi-font-size: 11.0pt"&gt;&lt;FONT size=4&gt;Abstract&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/U&gt;&lt;/I&gt;&lt;I style="mso-bidi-font-style: normal"&gt;&lt;U&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: green; FONT-FAMILY: 'Book Antiqua'"&gt;&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/U&gt;&lt;/I&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;U&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: 'Book Antiqua'"&gt;&lt;o:p&gt;&lt;SPAN style="TEXT-DECORATION: none"&gt;&lt;/SPAN&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/U&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: 'Book Antiqua'"&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: 'Book Antiqua'"&gt;We can visualize composite control, the composition of existing controls that reuses the implementation provided by child controls for rendering, post back handling etc. While creating composite controls we don’t face too much of complexity. For example, if our composite control has a Textbox control, the post back data processing for the textbox will be automatically taken care of. Similarly, we can use the existing button control to capture the post back.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: 'Book Antiqua'"&gt;&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: 'Book Antiqua'"&gt;Composite control should have: -&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: 'Book Antiqua'"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;OL style="MARGIN-TOP: 0in" type=1&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: 'Book Antiqua'"&gt;Overridden &lt;I style="mso-bidi-font-style: normal"&gt;&lt;SPAN style="COLOR: maroon"&gt;CreateChildControl&lt;/SPAN&gt; method &lt;/I&gt;that will have the logic implemented for initializing, instantiating, and finally adding the child controls in the control tree. &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;I style="mso-bidi-font-style: normal"&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: maroon; FONT-FAMILY: 'Book Antiqua'"&gt;System.Web.UI.INamingContainer&lt;/SPAN&gt;&lt;/I&gt;&lt;SPAN style="FONT-SIZE: 11pt; COLOR: maroon; FONT-FAMILY: 'Book Antiqua'"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: 'Book Antiqua'"&gt;interface implemented. It is a markup interface that doesn’t have any method but it will ensure that page framework will create unique identifiers for each and every control on the page by introducing &lt;I style="mso-bidi-font-style: normal"&gt;&lt;SPAN style="COLOR: maroon"&gt;UniqueID&lt;/SPAN&gt;&lt;/I&gt; property. Most of the developers complain that state of the child control is not persisting on post backs within the composite control. It is because; composite control is not implemented by &lt;I style="mso-bidi-font-style: normal"&gt;INamingContainer&lt;/I&gt; interface.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt; 
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: 'Book Antiqua'"&gt;We may want to use &lt;I style="mso-bidi-font-style: normal"&gt;&lt;SPAN style="COLOR: maroon"&gt;EnsureChildControls&lt;/SPAN&gt; &lt;/I&gt;method before we try to access any child control in the composite control. This method checks whether the child controls have been created and if not first invokes &lt;I style="mso-bidi-font-style: normal"&gt;&lt;SPAN style="COLOR: maroon"&gt;CreateChildControl&lt;/SPAN&gt; &lt;/I&gt;on that. &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;
&lt;LI class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: 'Book Antiqua'"&gt;We may also want to override &lt;I style="mso-bidi-font-style: normal"&gt;Controls &lt;/I&gt;property of the base class which returns &lt;I style="mso-bidi-font-style: normal"&gt;&lt;SPAN style="COLOR: maroon"&gt;ControlCollection&lt;/SPAN&gt; &lt;/I&gt;that can be utilized to call functionality such as &lt;I style="mso-bidi-font-style: normal"&gt;Add, Remove or Clear &lt;/I&gt;in the controls collection. Before returning control collection, we will call &lt;I style="mso-bidi-font-style: normal"&gt;EnsureChildControls &lt;/I&gt;API.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/LI&gt;&lt;/OL&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: 'Book Antiqua'"&gt;Hope this helps!!!&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 11pt; FONT-FAMILY: 'Book Antiqua'"&gt;Parag&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=549407" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/Custom+Control+Development/default.aspx">Custom Control Development</category></item><item><title>Understanding Login Controls in ASP.NET 2.0</title><link>http://blogs.msdn.com/paraga/archive/2006/03/10/Login-Controls.aspx</link><pubDate>Fri, 10 Mar 2006 17:40:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:548526</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/paraga/comments/548526.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=548526</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=548526</wfw:comment><description>&lt;P&gt;The link below explains what are the Login Controls and how they can be used against custom&amp;nbsp;data source instead of SQL Server by creating the custom Membership Provider classes.&lt;/P&gt;
&lt;P&gt;&lt;A href="http://support.microsoft.com/kb/910440/en-us"&gt;http://support.microsoft.com/kb/910440/en-us&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;By creating the custom membership provider described in the above article, we will still be using the fields that are provided by&amp;nbsp;MembershipUser class (&lt;A href="http://msdn2.microsoft.com/en-us/library/system.web.security.membershipuser_members(VS.80).aspx"&gt;http://msdn2.microsoft.com/en-us/library/system.web.security.membershipuser_members(VS.80).aspx&lt;/A&gt;). In order to use extra fields that exists in&amp;nbsp;the custom data source we need to extend MembershipUser class as well.&lt;/P&gt;
&lt;P&gt;Hope this helps!!!&lt;/P&gt;
&lt;P&gt;Parag&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=548526" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/ASP.NET+2.0/default.aspx">ASP.NET 2.0</category></item><item><title>Getting 'Webform_Postbackoptions is undefined’ errors in ASP.NET 2.0</title><link>http://blogs.msdn.com/paraga/archive/2006/02/02/522766.aspx</link><pubDate>Thu, 02 Feb 2006 06:08:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:522766</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>13</slash:comments><comments>http://blogs.msdn.com/paraga/comments/522766.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=522766</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=522766</wfw:comment><description>&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;&lt;font color=#006400&gt;Issue&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;&lt;font color=#006400&gt;====&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;I recently got an issue where customer ASP.NET 2.0 website on IIS and on one of the aspx pages he was using &lt;i style="mso-bidi-font-style: normal"&gt;RangeValidator&lt;/i&gt; control. Browsing to that aspx page was giving client side Java script errors ‘&lt;/span&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;Webform_Postbackoptions is undefined&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;’. Without RangeValidator application was just working fine.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;&lt;font color=#006400&gt;Cause&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;&lt;font color=#006400&gt;====&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;i style="mso-bidi-font-style: normal"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;WebResources.axd&lt;/span&gt;&lt;/i&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt; was not getting downloaded to ‘Temporary Internet Files’ folder. &lt;strong&gt;Fiddler showed 500 Status&lt;/strong&gt; for&lt;i style="mso-bidi-font-style: normal"&gt; &lt;/i&gt;the &lt;i style="mso-bidi-font-style: normal"&gt;WebResources.axd&lt;/i&gt;. IIS Logs showed nothing in my case. When directly browsed to this file it gave errors in one of the events called &lt;i style="mso-bidi-font-style: normal"&gt;AcquireRequestState&lt;/i&gt; in Global.asax file sitting under &lt;i style="mso-bidi-font-style: normal"&gt;App_Code&lt;/i&gt; directory. Error was related to session state because an AXD file doesn’t have any session state handler associated. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;&lt;font color=#006400&gt;Resolution&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;&lt;font color=#006400&gt;=======&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-family: 'Times New Roman'; mso-ansi-language: EN-US; mso-fareast-font-family: 'Times New Roman'; mso-fareast-language: EN-US; mso-bidi-language: AR-SA"&gt;Commented out AcquireRequestState event and now webresources.axd is successfully downloading in ‘Temporary Internet Files’ folder.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-family: 'Times New Roman'; mso-ansi-language: EN-US; mso-fareast-font-family: 'Times New Roman'; mso-fareast-language: EN-US; mso-bidi-language: AR-SA"&gt;&lt;strong&gt;Note&lt;/strong&gt;:- Fiddler tool can be downloaded from &lt;a href="http://www.fiddlertool.com/dl/FiddlerSetup.exe"&gt;http://www.fiddlertool.com/dl/FiddlerSetup.exe&lt;/a&gt;. It's a great tool to troubleshoot client side issues.&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-family: 'Times New Roman'; mso-ansi-language: EN-US; mso-fareast-font-family: 'Times New Roman'; mso-fareast-language: EN-US; mso-bidi-language: AR-SA"&gt;&lt;/span&gt;&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=522766" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/ASP.NET+2.0/default.aspx">ASP.NET 2.0</category></item><item><title>Intermittently Loosing Intellisense in the code behind editor inside visual studio .net</title><link>http://blogs.msdn.com/paraga/archive/2006/02/02/Intellisense-Visual-Studio.aspx</link><pubDate>Thu, 02 Feb 2006 05:59:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:522754</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/paraga/comments/522754.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=522754</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=522754</wfw:comment><description>&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;/span&gt;&amp;nbsp;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;font color=#006400&gt;&lt;strong&gt;Issue&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/strong&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;font color=#006400&gt;&lt;strong&gt;====&lt;o:p&gt;&lt;/o:p&gt;&lt;/strong&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;One of my colleagues was loosing intellisense in the code behind editor for a particular ASPX page intermittently in visual studio .net 2003. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;&lt;font color=#006400&gt;Cause&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;&lt;font color=#006400&gt;=====&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Later we found out that he edited the &lt;i style="mso-bidi-font-style: normal"&gt;InitializeComponent&lt;/i&gt; method by adding the code below:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'"&gt;private&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"&gt; &lt;span style="COLOR: blue"&gt;void&lt;/span&gt; InitializeComponent()&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"&gt;{&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'"&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/span&gt;if&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"&gt; (Session["AnyVariable"] == &lt;span style="COLOR: blue"&gt;null&lt;/span&gt;)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;Server.Transfer("frm.aspx");&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: 'Courier New'"&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/span&gt;this&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"&gt;.Load += &lt;span style="COLOR: blue"&gt;new&lt;/span&gt; System.EventHandler(&lt;span style="COLOR: blue"&gt;this&lt;/span&gt;.Page_Load);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: 'Courier New'"&gt;}&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;&lt;font color=#006400&gt;Steps taken to find the root cause&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;&lt;font color=#006400&gt;=======================&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;ol style="MARGIN-TOP: 0in" type=1&gt;
&lt;li class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Opened up new visual studio instance.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Go to Tools -&amp;gt; Debug Processes.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Attach devenv.exe associated with faulty project.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Then go to Debug menu, and select Exceptions.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;For each Exception listed, select the option, “Break into the debugger”.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;After that open up the problematic ASPX file. Opening up that file resulted into the following exception:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;em&gt;A first chance exception of type 'System.ComponentModel.Design.Serialization.CodeDomSerializerException' occurred in microsoft.visualstudio.dll&lt;o:p&gt;&lt;/o:p&gt;&lt;/em&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;o:p&gt;&lt;em&gt;&amp;nbsp;&lt;/em&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;em&gt;Additional information: The designer cannot process the code at line 40: &lt;o:p&gt;&lt;/o:p&gt;&lt;/em&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;o:p&gt;&lt;em&gt;&amp;nbsp;&lt;/em&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;em&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;if (Session["&lt;/span&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: 'Courier New'; mso-bidi-font-size: 10.0pt"&gt;AnyVariable&lt;/span&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;"] == null)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;em&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/span&gt;Server.Transfer("frm.aspx");&lt;o:p&gt;&lt;/o:p&gt;&lt;/em&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;o:p&gt;&lt;em&gt;&amp;nbsp;&lt;/em&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;em&gt;The code within the method 'InitializeComponent' is generated by the designer and should not be manually modified.&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/span&gt;Please remove any changes and try opening the designer again.&lt;/em&gt;&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;Resolution&lt;o:p&gt;&lt;/o:p&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;=======&lt;/strong&gt;&lt;/span&gt;&lt;/p&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-family: 'Times New Roman'; mso-ansi-language: EN-US; mso-fareast-font-family: 'Times New Roman'; mso-fareast-language: EN-US; mso-bidi-language: AR-SA"&gt;Removed the code from the &lt;i style="mso-bidi-font-style: normal"&gt;InitializeComponent&lt;/i&gt; method.&lt;/span&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=522754" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/Misc.+Category/default.aspx">Misc. Category</category></item><item><title>Using Web Deployment Project in Visual Studio 2005</title><link>http://blogs.msdn.com/paraga/archive/2006/02/02/522748.aspx</link><pubDate>Thu, 02 Feb 2006 05:49:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:522748</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/paraga/comments/522748.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=522748</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=522748</wfw:comment><description>&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;/span&gt;&amp;nbsp;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;font color=#006400&gt;Issue&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;font color=#006400&gt;====&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;One of my colleague&amp;nbsp;developed ASP.NET 2.0 application in Visual studio 2005. During the development phase he referenced few assemblies from a shared directory that were not in GAC. As a result, all the referenced assemblies&amp;nbsp;were copied in Bin folder. Now he wants a functionality to exclude all those assemblies that are present in bin folder as soon as he publishes the website to other location.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;font color=#006400&gt;Resolution&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;font color=#006400&gt;========&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;There are two ways to achieve the above functionality:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;ol style="MARGIN-TOP: 0in" type=1&gt;
&lt;li class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Reference all the assemblies from GAC. As a result adding a reference in the website will not create a Bin folder. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li class=MsoNormal style="MARGIN: 0in 0in 0pt; tab-stops: list .5in; mso-list: l0 level1 lfo1"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Use Web Deployment Project utility where we can exclude the paths when ever the build will happen in its configuration file like:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;
&lt;p class=Code style="MARGIN: 0in 0in 3pt; TEXT-INDENT: 0.5in"&gt;&lt;span style="FONT-SIZE: 9pt; mso-bidi-font-size: 10.0pt"&gt;&lt;font face="Courier New"&gt;&lt;font color=#800080&gt;&amp;lt;ItemGroup&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=Code style="MARGIN: 0in 0in 3pt"&gt;&lt;span style="FONT-SIZE: 9pt; mso-bidi-font-size: 10.0pt"&gt;&lt;font face="Courier New"&gt;&lt;font color=#800080&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-tab-count: 1"&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&amp;lt;ExcludeFromBuild&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=Code style="MARGIN: 0in 0in 3pt"&gt;&lt;span style="FONT-SIZE: 9pt; mso-bidi-font-size: 10.0pt"&gt;&lt;font face="Courier New"&gt;&lt;font color=#800080&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;include="$(SourceWebPhysicalPath)\Bin\*.*"/&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=Code style="MARGIN: 0in 0in 3pt"&gt;&lt;span style="FONT-SIZE: 9pt; mso-bidi-font-size: 10.0pt"&gt;&lt;font face="Courier New"&gt;&lt;font color=#800080&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/span&gt;&amp;lt;/ItemGroup&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;For more information on Web Deployment project, visit the following links:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;a href="http://msdn.microsoft.com/asp.net/reference/infrastructure/wdp/"&gt;http://msdn.microsoft.com/asp.net/reference/infrastructure/wdp/&lt;/a&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;a href="http://download.microsoft.com/download/1/5/4/1541980a-d8fc-407b-8c9f-c2df5445b041/Using%20web_deployment_projects_final.doc"&gt;http://download.microsoft.com/download/1/5/4/1541980a-d8fc-407b-8c9f-c2df5445b041/Using%20web_deployment_projects_final.doc&lt;/a&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=522748" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/ASP.NET+2.0/default.aspx">ASP.NET 2.0</category></item><item><title>HTTP_URL Server Variable behaves differently in IIS 5 and 6</title><link>http://blogs.msdn.com/paraga/archive/2006/02/02/HTTP-URL.aspx</link><pubDate>Thu, 02 Feb 2006 05:44:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:522746</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/paraga/comments/522746.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=522746</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=522746</wfw:comment><description>&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;font color=#006400&gt;&lt;/font&gt;&lt;/span&gt;&amp;nbsp;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;font color=#006400&gt;Issue&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;font color=#006400&gt;====&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;One of my Customer’s configured an ASP file named *&lt;span style="COLOR: maroon"&gt;NotFound.asp&lt;/span&gt;* to process 404 errors inside the Custom Errors section of Internet Services Manager, where he uses HTTP_URL Property to get the bad page or malformed URL that user has just requested. There he is maintaining two Arrays. First array represents the list of bad/old URL and the second array maps to their latest version available. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Initially the application was developed on IIS 5. Migrating it to IIS 6 started giving problems because of the following reason(s):&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;He is storing the URL’s in Array as &lt;a href="http://machinename/VdirName/Pagename.asp%20i.e"&gt;http://machinename/VdirName/Pagename.asp i.e&lt;/a&gt;. without PORT information because HTTP_URL doesn’t include the PORT information in IIS 5 or the versions below it.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;As soon as he retrieves the Bad page as:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;var badPage = Request.ServerVariable(“HTTP_URL”),&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: maroon; FONT-FAMILY: Verdana"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;He strips off *&lt;span style="COLOR: maroon"&gt;404;&lt;/span&gt;* part from the badPage and queries on the second array to get its newer counterpart. The logic works on IIS 5 but fails on IIS 6 because HTTP_URL now include PORT information even with the default web site running on PORT 80 which he has not handled in the code right now.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Now he is asking whether there is some setting on IIS 6 that specifies not to include the PORT number in the HTTP_URL variable. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;Actually there is no such setting in IIS 6 where we can specify not to use PORT number in the return URL. We have to handle this situation only by writing code that will strip off the PORT information from the bad page before any lookup operation. I also tried searching this information on support site as well as visual KB but couldn’t find anything.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;font color=#006400&gt;WORKAROUND&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;font color=#006400&gt;==========&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&amp;lt;%&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;Function parseUrl(url)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/span&gt;firstpartlength =&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/span&gt;instr(6, url,":")-1&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/span&gt;If firstpartlength &amp;gt; 0 Then&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp;&lt;/span&gt;firstpart = mid(&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/span&gt;url,&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/span&gt;1,firstpartlength)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;lastpartindex = instr(firstpartlength, url,"/")&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;lastpart = mid(url,lastpartindex)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;url = (firstpart &amp;amp; lastpart)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/span&gt;End If&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;&amp;nbsp; &lt;/span&gt;parseUrl= url&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;End Function&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;%&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 9pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 10.0pt"&gt;&amp;lt;%= parseUrl("http://machinename:&lt;b style="mso-bidi-font-weight: normal"&gt;8080&lt;/b&gt;/Vdir/BadPage.asp")%&amp;gt;&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana"&gt;&lt;strong&gt;NOTE&lt;/strong&gt;:- On IIS 5, even if Default Web site is running on some other PORT instead of PORT 80, HTTP_URL will still not display the URL with a PORT number. It can be considered as a BUG or Limitation on IIS 5.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=522746" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/Support+Cases/default.aspx">Support Cases</category></item><item><title>ASP.NET 2.0 - Cannot find control in EditItemTemplate of DetailsView Control</title><link>http://blogs.msdn.com/paraga/archive/2006/01/16/DetailsView.aspx</link><pubDate>Mon, 16 Jan 2006 06:30:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:513186</guid><dc:creator>Parag Agarwal</dc:creator><slash:comments>0</slash:comments><comments>http://blogs.msdn.com/paraga/comments/513186.aspx</comments><wfw:commentRss>http://blogs.msdn.com/paraga/commentrss.aspx?PostID=513186</wfw:commentRss><wfw:comment>http://blogs.msdn.com/paraga/rsscomments.aspx?PostID=513186</wfw:comment><description>&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;Recently we got some cases in ASP.NET 2.0, where customers were using: - &lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;- DetailsView control bound with SQL Data source control.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;- DetailsView has few Data-bound Columns as well as one Template Column.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;- Data bound columns displays correct values.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;- However, there are some issues with Templated Column that looks like:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&amp;lt;asp:TemplateField HeaderText="BusinessOrgName" SortExpression="BusinessOrgName"&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&amp;lt;EditItemTemplate&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoBodyText style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 8pt; mso-bidi-font-size: 12.0pt"&gt;&lt;FONT color=#800000&gt;&lt;FONT face=Verdana&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;asp:ListBox ID="LstBUOrg" runat="server" AutoPostBack="true" DataSourceID="BUOrgDataSource"&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 8pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="COLOR: maroon"&gt;DataTextField="BusinessOrgName" Width="347px" DataValueField="BusinessOrgID" SelectionMode="Multiple"&amp;nbsp;&lt;/SPAN&gt;&lt;B&gt; &lt;/B&gt;&lt;SPAN style="COLOR: maroon"&gt;SelectedValue='&amp;lt;%# Bind("BusinessOrgID") %&amp;gt;'&amp;gt;&lt;/SPAN&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/asp:ListBox&amp;gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/EditItemTemplate&amp;gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&amp;lt;ItemTemplate&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoBodyText style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 8pt; mso-bidi-font-size: 12.0pt"&gt;&lt;FONT color=#800000&gt;&lt;FONT face=Verdana&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;asp:Label ID="LblBOrg" runat="server" Text='&amp;lt;%# Bind("BusinessOrgName") %&amp;gt;'&amp;gt;&amp;lt;/asp:Label&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&amp;lt;/ItemTemplate&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 8pt; COLOR: maroon; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&amp;lt;/asp:TemplateField&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE: 8pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;- Most of the time, Template Column works fine but with one exception. Exception is, when Label control inside &amp;lt;ItemTemplate&amp;gt; is blank. As a result, when user switches to DetailsView Edit mode, where SelectedValue property of the ListBox control is used, we get error stating "&lt;I&gt;Value that we are trying to select is not present in the Listbox Items&lt;/I&gt;”, which is basically a NULL value. &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;Now how to avoid this situation to happen?&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;FONT color=#006400&gt;RESOLUTION&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;FONT color=#006400&gt;==========&lt;o:p&gt;&lt;/o:p&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;- To get rid of this situation, some of the customers were trying to get the reference of the ListBox control, as soon as the Label is blank so that they can change the SelectedValue property dynamically.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;- That seems to be a good idea, but the events like (ModeChanged/ModeChanging) where they want to get this job done are not appropriate.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;- This&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;is&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;because; we&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;cannot&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;get&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;the&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;Listbox&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;reference&lt;SPAN style="mso-spacerun: yes"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;under ModeChanged/ModeChanging events as Listbox control under &amp;lt;EditItemTemplate&amp;gt; is still not built at this time. &lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;- We will get the reference of Listbox control inside ItemUpdated(ItemUpdating) event that will be called while Updating the DetailsView control. But for the above situation, that we will too late because we will get the error as soon as user switches to edit mode with a blank label.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;- Only way left is to implement OnPreRender event for Listbox control inside &amp;lt;EditItemTemplate&amp;gt; where SelectedValue property is set to null if the Label is blank.&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;To learn more about DetailsView control, visit the following link:&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;A href="https://aps.mail.microsoft.com/exchweb/bin/redir.asp?URL=http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnaspp/html/detailsview.asp" target=_blank&gt;&lt;SPAN style="mso-bidi-font-size: 10.0pt"&gt;http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnaspp/html/detailsview.asp&lt;/SPAN&gt;&lt;/A&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;Hope this helps!! Please feel free to send me an email if you have any questions.&lt;/o:p&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoNormal style="MARGIN: 0in 0in 0pt"&gt;&lt;SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Verdana; mso-bidi-font-size: 12.0pt"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=513186" width="1" height="1"&gt;</description><category domain="http://blogs.msdn.com/paraga/archive/tags/Support+Cases/default.aspx">Support Cases</category></item></channel></rss>