<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.asp.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>zc0000</title><link>http://weblogs.asp.net/atlaszhu/default.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>Solution to the alert "The object identifier does not present a valid object" when trying to debug IIS-supplied applications through VS</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/08/31/solution-to-the-alert-quot-the-object-identifier-does-not-present-a-valid-object-quot-when-trying-to-debug-iis-supplied-applications-through-vs.aspx</link><pubDate>Mon, 31 Aug 2009 10:12:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7186333</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7186333</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/08/31/solution-to-the-alert-quot-the-object-identifier-does-not-present-a-valid-object-quot-when-trying-to-debug-iis-supplied-applications-through-vs.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;&amp;nbsp;Met the error and felt wield ...&amp;nbsp;&amp;nbsp; &lt;/P&gt;
&lt;P mce_keep="true"&gt;Then I found a great article to explain the reason and point to the key of truth.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;A href="http://blogs.iis.net/brian-murphy-booth/archive/2008/06/03/visual-studio-2008-unable-to-debug-asp-net-app-on-iis-7-0.aspx"&gt;http://blogs.iis.net/brian-murphy-booth/archive/2008/06/03/visual-studio-2008-unable-to-debug-asp-net-app-on-iis-7-0.aspx&lt;/A&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;---------------------------------------------------------------------------------------------------------------&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;When attempting to&amp;nbsp;"run" an ASP.NET&amp;nbsp;project on IIS 7.0 using Visual Studio 2008 the following error is displayed:&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;A href="http://blogs.iis.net/blogs/brian-murphy-booth/0x800710D8.jpg"&gt;&lt;IMG title="Unable to start debugging on the web server. The object identifier does not represent a valid object. (Exception from HRESULT: 0x800710D8)" border=0 alt="Unable to start debugging on the web server. The object identifier does not represent a valid object. (Exception from HRESULT: 0x800710D8)" src="http://blogs.iis.net/blogs/brian-murphy-booth/0x800710D8.jpg" mce_src="http://blogs.iis.net/blogs/brian-murphy-booth/0x800710D8.jpg"&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;RESOLUTION:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp; Make sure that "Windows Authentication" is enabled in IIS on the applicable&amp;nbsp;web application (web site or folder).&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;NOTES:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;That was a little frustrating for me at first. No hits anywhere in our knowledge base or on &lt;A href="http://www.live.com/" mce_href="http://www.live.com"&gt;Live&lt;/A&gt;. I figured I would ignore this and come back to it later but after about a week I finally decided this isn't something I wanted to deal with constantly.&amp;nbsp;I started&amp;nbsp;to troubleshoot it versus waiting to find somebody else's solution. One of the first things Visual Studio does when trying to debug an ASP.NET application is make a DEBUG request (versus a GET or POST) to IIS. If all goes well for the DEBUG request, VS automatically attaches as a debugger to the ASP.NET worker process (w3wp.exe in this case) and to IEXPLORE.exe. So into the&amp;nbsp;IIS logs I went to see the result of that DEBUG request. Here was the entry for my failed debug attempt:&lt;/P&gt;
&lt;P mce_keep="true"&gt;#Software: Microsoft Internet Information Services 7.0&lt;BR&gt;#Version: 1.0&lt;BR&gt;#Date: 2008-06-03 12:11:16&lt;BR&gt;#Fields: date time s-ip cs-method cs-uri-stem cs-uri-query s-port cs-username c-ip cs(User-Agent) cs(Cookie) sc-status sc-substatus sc-win32-status time-taken&lt;BR&gt;2008-06-03 12:11:16 ::1 DEBUG /WebApp/Default.aspx - 80 - ::1 - - 401 0 0 157&lt;/P&gt;
&lt;P mce_keep="true"&gt;You may notice that this is a&amp;nbsp;401.0. Normally when a "browser" (VS2008 in this case) first makes a request it is always anonymous. Then after&amp;nbsp;seeing a 401, it will follow&amp;nbsp;up the first request with a second request that includes credentials. In the IIS logs&amp;nbsp;we'd expect to see a 401.2 (unauthorized due to sever configuration - i.e. I'm not accepting anonynous), then if using NTLM we'd see a 401.1 (NTLM challenge - i.e. you have only sent me half the credentials for that NTLM handshake) then finally a success status such as 200 (OK), 302 (Moved/Redirect), or 304 (Not Modified). Or if using Basic authentication or Kerberos there would be the 401.2 then the success status for the next log entry since those methods don't have a handshake. In my case here there was only a single 401 with no follow up attempt. Hmm... Why no follow up request with credentials? Next stop - IIS manager.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;A href="http://blogs.iis.net/blogs/brian-murphy-booth/0x800710D8.Authentication.jpg"&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;A href="http://blogs.iis.net/blogs/brian-murphy-booth/0x800710D8.Authentication.jpg"&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;A href="http://blogs.iis.net/blogs/brian-murphy-booth/0x800710D8.Authentication.jpg"&gt;&lt;IMG border=0 src="http://blogs.iis.net/blogs/brian-murphy-booth/0x800710D8.Authentication.jpg"&gt;&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;After highlighting my "WebApp" folder and double-clicking "Authentication" (shown above)&amp;nbsp;in the IIS manager I saw that only Anonymous was enabled. Oh right... IIS 7.0 is secure by default. VS was making it's anonymous request and since IIS returned no "WWW-Authentication" headers specifying which auth method it is accepting, VS quit there. IIS 7.0&amp;nbsp;has only anonymous enabled by default and administrators have to consciously open up their server by enabling additional authentication types. After enabling "Windows Authentication" as well leaving&amp;nbsp;"Anonymous" enabled, debugging worked fine. Thanks for the great error!!&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7186333" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/Visual+Studio+2008/default.aspx">Visual Studio 2008</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/iis7/default.aspx">iis7</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/debug/default.aspx">debug</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/windows+authentication/default.aspx">windows authentication</category></item><item><title>Alert Cannot set a credential for principal 'sa' ....   when trying to modify 'sa' properties through sql management studio 2008..</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/08/08/alert-cannot-set-a-credential-for-principal-sa-when-trying-to-modify-sa-properties-through-sql-management-studio-2008.aspx</link><pubDate>Sat, 08 Aug 2009 13:35:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7164351</guid><dc:creator>zc0000</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7164351</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/08/08/alert-cannot-set-a-credential-for-principal-sa-when-trying-to-modify-sa-properties-through-sql-management-studio-2008.aspx#comments</comments><description>&lt;H1 class=title&gt;&lt;A href="http://support.microsoft.com/kb/956177"&gt;http://support.microsoft.com/kb/956177&lt;/A&gt;&amp;nbsp;&amp;nbsp;&lt;/H1&gt;
&lt;H1 class=title&gt;&amp;nbsp;&amp;nbsp;&lt;/H1&gt;
&lt;H1 class=title&gt;You receive an exception in SQL Server 2008 when you try to modify the properties of the SQL Server Administrator account by using SQL Server Management Studio&lt;/H1&gt;
&lt;P class=title mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;H2 id=tocHeadRef class=subTitle jQuery1249738307543="13"&gt;
&lt;DIV class="kb_tabs_toggle kb_tabs_toggle_open" jQuery1249738307543="22"&gt;&lt;/DIV&gt;&lt;SPAN&gt;&lt;A href="javascript:void(0);" jQuery1249738307543="51"&gt;SYMPTOMS&lt;/A&gt;&lt;/SPAN&gt; 
&lt;DIV class=sectionpreview_closed jQuery1249738307543="23"&gt;Consider the following scenario. You use the Microsoft SQL Server 2008 tools to...&lt;/DIV&gt;&lt;/H2&gt;
&lt;SCRIPT type=text/javascript&gt;
                            loadTOCNode(1, 'symptoms');
                        &lt;/SCRIPT&gt;

&lt;DIV style="MARGIN-LEFT: 195px" class=sbody jQuery1249738307543="24"&gt;Consider the following scenario. You use the Microsoft SQL Server 2008 tools to connect to a server that is running Microsoft SQL Server 2005. You open the properties dialog box for the SQL Server Administrator account, and then you perform an "sa" login by using the SQL Server Management Studio tools. You modify the properties for the "sa" login, and then you click &lt;STRONG class=uiterm&gt;OK&lt;/STRONG&gt;. In this scenario, you receive the following error message: 
&lt;DIV class=kb_errormsgbody jQuery1249738307543="25"&gt;
&lt;DIV class=kb_errorcontent jQuery1249738307543="26"&gt;
&lt;DIV class=errormsg jQuery1249738307543="27"&gt;TITLE: Microsoft SQL Server Management Studio &lt;BR&gt;------------------------------ &lt;BR&gt;Alter failed for Login 'sa'. (Microsoft.SqlServer.Smo)&lt;BR&gt;------------------------------&lt;BR&gt;ADDITIONAL INFORMATION: An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)&lt;BR&gt;------------------------------&lt;BR&gt;Cannot set a credential for principal 'sa'. (Microsoft SQL Server, Error: 15535)&lt;BR&gt;------------------------------&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;
&lt;DIV class=topOfPage jQuery1249738307543="28"&gt;&lt;A href="http://support.microsoft.com/kb/956177#top" jQuery1249738307543="52"&gt;&lt;IMG alt="" src="http://support.microsoft.com/library/images/support/kbgraphics/public/en-us/uparrow.gif"&gt;Back to the top&lt;/A&gt;&lt;/DIV&gt;&lt;/DIV&gt;
&lt;H2 id=tocHeadRef class=subTitle jQuery1249738307543="14"&gt;
&lt;DIV class="kb_tabs_toggle kb_tabs_toggle_open" jQuery1249738307543="29"&gt;&lt;/DIV&gt;&lt;SPAN&gt;&lt;A href="javascript:void(0);" jQuery1249738307543="53"&gt;CAUSE&lt;/A&gt;&lt;/SPAN&gt; 
&lt;DIV class=sectionpreview_closed jQuery1249738307543="30"&gt;This problem occurs if the Map To Credential check box is not selected on the Ge...&lt;/DIV&gt;&lt;/H2&gt;
&lt;SCRIPT type=text/javascript&gt;
                            loadTOCNode(1, 'cause');
                        &lt;/SCRIPT&gt;

&lt;DIV style="MARGIN-LEFT: 195px" class=sbody jQuery1249738307543="31"&gt;This problem occurs if the &lt;STRONG class=uiterm&gt;Map To Credential&lt;/STRONG&gt; check box is not selected on the &lt;STRONG class=uiterm&gt;General&lt;/STRONG&gt; tab of the &lt;STRONG class=uiterm&gt;Login Properties - sa&lt;/STRONG&gt; dialog box. If this check box is not selected, SQL Server 2008 will try to drop any credential that is mapped to your login credentials. Because your credentials cannot be set to the "sa" login, you receive the exception error message that is mentioned in the "Symptoms" section when you click &lt;STRONG class=uiterm&gt;OK&lt;/STRONG&gt; to close the dialog box. 
&lt;DIV class=topOfPage jQuery1249738307543="32"&gt;&lt;A href="http://support.microsoft.com/kb/956177#top" jQuery1249738307543="54"&gt;&lt;IMG alt="" src="http://support.microsoft.com/library/images/support/kbgraphics/public/en-us/uparrow.gif"&gt;Back to the top&lt;/A&gt;&lt;/DIV&gt;&lt;/DIV&gt;
&lt;H2 id=tocHeadRef class=subTitle jQuery1249738307543="15"&gt;
&lt;DIV class="kb_tabs_toggle kb_tabs_toggle_open" jQuery1249738307543="33"&gt;&lt;/DIV&gt;&lt;SPAN&gt;&lt;A href="javascript:void(0);" jQuery1249738307543="55"&gt;RESOLUTION&lt;/A&gt;&lt;/SPAN&gt; 
&lt;DIV class=sectionpreview_closed jQuery1249738307543="34"&gt;To resolve this issue, make sure that you select the Map To Credential check box...&lt;/DIV&gt;&lt;/H2&gt;
&lt;SCRIPT type=text/javascript&gt;
                            loadTOCNode(1, 'resolution');
                        &lt;/SCRIPT&gt;

&lt;DIV style="MARGIN-LEFT: 195px" class=sbody jQuery1249738307543="35"&gt;To resolve this issue, make sure that you select the &lt;STRONG class=uiterm&gt;Map To Credential&lt;/STRONG&gt; check box on the &lt;STRONG class=uiterm&gt;General&lt;/STRONG&gt; tab of the &lt;STRONG class=uiterm&gt;Login Properties - sa&lt;/STRONG&gt; dialog box before you change the "sa" login properties and then click &lt;STRONG class=uiterm&gt;OK&lt;/STRONG&gt; to close the dialog box.&lt;/DIV&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7164351" width="1" height="1"&gt;</description></item><item><title> IIS7  FTP settings  Instruction .....</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/08/08/iis7-ftp-settings-instruction.aspx</link><pubDate>Sat, 08 Aug 2009 09:16:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7164217</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7164217</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/08/08/iis7-ftp-settings-instruction.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;IIS7&amp;nbsp; FTP settings&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;A href="http://learn.iis.net/page.aspx/320/using-ftp-virtual-host-names/" mce_href="http://learn.iis.net/page.aspx/320/using-ftp-virtual-host-names/"&gt;http://learn.iis.net/page.aspx/320/using-ftp-virtual-host-names/&lt;/A&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;FTP&amp;nbsp; 绑定之时，如果需要使用域名访问，则不但要绑定 FTP 域名&amp;nbsp; &lt;A href="ftp://ftp.domain.com/"&gt;ftp.domain.com&lt;/A&gt; （一个绑定记录），还必须要一个 unassigned 绑定，直接绑定IP ！&lt;/P&gt;
&lt;P mce_keep="true"&gt;两条绑定记录都是必须的！ &lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7164217" width="1" height="1"&gt;</description></item><item><title>Solve an alert occuring when trying to save in ManagementStudio Table-design interface:Saving changes is not permitted</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/07/19/solve-an-alert-occuring-when-trying-to-save-in-managementstudio-table-design-interface-saving-changes-is-not-permitted.aspx</link><pubDate>Sun, 19 Jul 2009 12:31:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7150777</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7150777</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/07/19/solve-an-alert-occuring-when-trying-to-save-in-managementstudio-table-design-interface-saving-changes-is-not-permitted.aspx#comments</comments><description>&lt;H1&gt;&amp;nbsp;&amp;nbsp;Saving changes is not permitted. The changes that you have made require the following tables to be dropped and re-created.&lt;/H1&gt;
&lt;P mce_keep="true"&gt;
&lt;TABLE border=0 cellSpacing=0 cellPadding=0 width="100%"&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD class=authandpub align=left&gt;&lt;BR&gt;&lt;/TD&gt;
&lt;TD align=right&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;BR&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;ERROR:&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'; COLOR: red" class=text&gt;“Saving changes is not permitted. The changes that you have made require the following tables to be dropped and re-created. You have either made changes to a table that can't be re-created or enabled the option Prevent saving changes that require the table to be re-created.”&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;This error happens because “&lt;STRONG&gt;Saving Changes is not permitted&lt;/STRONG&gt;” when using SQL Server 2008 Management Studio to modify the structure of a table especially when SQL Server needs to drop and recreate a table to save the structural changes. It is always advised to make a structural change for a table using TSQL. However, it is a convenient option for database developers to use SQL Server Management Studio make such changes&amp;nbsp; as the&amp;nbsp; &lt;EM&gt;Prevent Saving Changes That Require Table Re-creation&lt;/EM&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;option is enabled by default in SQL Server 2008 Management Studio.&lt;BR&gt;&lt;BR&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;&lt;FONT color=#3366cc&gt;&lt;SPAN class=titles&gt;&lt;EM&gt;&lt;STRONG&gt;Disable “Prevent saving changes that require the table re-creation” &lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;BR&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoListParagraphCxSpMiddle&gt;&lt;FONT color=#3366cc&gt;&lt;SPAN class=text&gt;&lt;STRONG&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'; COLOR: black" class=text&gt;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;STRONG&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;STRONG&gt;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify; TEXT-INDENT: -0.25in" class=MsoListParagraphCxSpFirst&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;1.&lt;SPAN style="LINE-HEIGHT: normal; FONT-VARIANT: normal; FONT-STYLE: normal; FONT-FAMILY: 'times new roman'; FONT-WEIGHT: normal; font-size-adjust: none; font-stretch: normal" class=text&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;Open SQL Server 2008 Management Studio (SSMS). Click Tools menu and then click on Options... as shown in the snippet below.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN class=text&gt;&lt;STRONG&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;&lt;IMG id="Picture 15" src="http://weblogs.asp.net/admin/article_images_new/2008_images/saving_changes_is_not_permitted_error_files/image001.jpg" width=429 height=193&gt;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;STRONG&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;&lt;BR&gt;&lt;BR&gt;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify; TEXT-INDENT: -0.25in" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;2.&lt;SPAN style="LINE-HEIGHT: normal; FONT-VARIANT: normal; FONT-STYLE: normal; FONT-FAMILY: 'times new roman'; FONT-WEIGHT: normal; font-size-adjust: none; font-stretch: normal" class=text&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;In the navigation pane of the Options window, expand Designers node and select &lt;STRONG&gt;Table and Database Designers&lt;/STRONG&gt; option as shown in the below snippet. Under Table Options you need to uncheck “&lt;STRONG&gt;Prevent saving changes that require the table re-creation” &lt;/STRONG&gt;option and click OK to save changes. &lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN class=text&gt;&lt;STRONG&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;&lt;IMG id="Picture 19" src="http://weblogs.asp.net/admin/article_images_new/2008_images/saving_changes_is_not_permitted_error_files/image002.jpg" width=547 height=325&gt;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;This option when enabled prevents users from making structural changes to table using SQL Server Management Studio especially when SQL Server needs to recreate the table to save changes. By default, this option is checked and you need to uncheck this option to allow users to make any structural change through SSMS that &amp;nbsp;&amp;nbsp;require table recreation. &lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;A table needs to be recreated whenever any of the below &amp;nbsp;&amp;nbsp;changes are made to the table structure. &lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify; TEXT-INDENT: -0.25in; MARGIN-LEFT: 1in" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: symbol" class=text&gt;·&lt;SPAN style="LINE-HEIGHT: normal; FONT-VARIANT: normal; FONT-STYLE: normal; FONT-FAMILY: 'times new roman'; FONT-WEIGHT: normal; font-size-adjust: none; font-stretch: normal" class=text&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;Insert a new column in the middle of the table.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify; TEXT-INDENT: -0.25in; MARGIN-LEFT: 1in" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: symbol" class=text&gt;·&lt;SPAN style="LINE-HEIGHT: normal; FONT-VARIANT: normal; FONT-STYLE: normal; FONT-FAMILY: 'times new roman'; FONT-WEIGHT: normal; font-size-adjust: none; font-stretch: normal" class=text&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;Add a new column in the table.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify; TEXT-INDENT: -0.25in; MARGIN-LEFT: 1in" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: symbol" class=text&gt;·&lt;SPAN style="LINE-HEIGHT: normal; FONT-VARIANT: normal; FONT-STYLE: normal; FONT-FAMILY: 'times new roman'; FONT-WEIGHT: normal; font-size-adjust: none; font-stretch: normal" class=text&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;Change the Allow Nulls setting of a column.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify; TEXT-INDENT: -0.25in; MARGIN-LEFT: 1in" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: symbol" class=text&gt;·&lt;SPAN style="LINE-HEIGHT: normal; FONT-VARIANT: normal; FONT-STYLE: normal; FONT-FAMILY: 'times new roman'; FONT-WEIGHT: normal; font-size-adjust: none; font-stretch: normal" class=text&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;Modify the identity property of a column.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify; TEXT-INDENT: -0.25in; MARGIN-LEFT: 1in" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: symbol" class=text&gt;·&lt;SPAN style="LINE-HEIGHT: normal; FONT-VARIANT: normal; FONT-STYLE: normal; FONT-FAMILY: 'times new roman'; FONT-WEIGHT: normal; font-size-adjust: none; font-stretch: normal" class=text&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;Reorder the columns within a table.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify; TEXT-INDENT: -0.25in; MARGIN-LEFT: 1in" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: symbol" class=text&gt;·&lt;SPAN style="LINE-HEIGHT: normal; FONT-VARIANT: normal; FONT-STYLE: normal; FONT-FAMILY: 'times new roman'; FONT-WEIGHT: normal; font-size-adjust: none; font-stretch: normal" class=text&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;Modify the datatype of a column.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;Once you have disabled “&lt;STRONG&gt;Prevent saving changes that require the table re-creation” &lt;/STRONG&gt;option you can go ahead and save the changes to the Employee Table. This will create a Validation Warning dialog box as shown in the below snippet. The warning message will be “&lt;STRONG&gt;One or more existing columns have ANSI_PADDING 'off' and will be re-created with ANSI_PADDING 'on'&lt;/STRONG&gt;”. Click “Yes” to save the changes.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;&lt;IMG id="Picture 20" src="http://weblogs.asp.net/admin/article_images_new/2008_images/saving_changes_is_not_permitted_error_files/image003.jpg" width=455 height=372&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoListParagraphCxSpMiddle&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoNormal&gt;&lt;SPAN class=titles&gt;&lt;EM&gt;&lt;STRONG&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=titles&gt;&lt;FONT color=#3366cc&gt;Risks of Turing Off "Prevent Saving Changes that Require Table Re-creation" in SSMS&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;STRONG&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;&lt;BR&gt;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;If you turn off this feature then you can avoid table recreation. However, if you have the Change Tracking feature of SQL Server 2008 enabled to track the table changes then the change tracking information will be lost completely whenever table is recreated. So, it is always advised to use this feature very carefully especially in a production environment.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="TEXT-ALIGN: justify" class=MsoNormal&gt;&lt;SPAN style="FONT-FAMILY: 'verdana', 'sans-serif'" class=text&gt;Refer to &lt;A href="http://www.sql-server-performance.com/faq/saving_changes_not_permitted_p1.aspx"&gt;http://www.sql-server-performance.com/faq/saving_changes_not_permitted_p1.aspx&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7150777" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/Sql+SERVER+2008/default.aspx">Sql SERVER 2008</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/Management+Studio/default.aspx">Management Studio</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/Save+Table+Design/default.aspx">Save Table Design</category></item><item><title>A CALLBACK function is always triggered at LAST in a code route !!</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/07/08/a-callback-function-is-always-trigered-at-last-in-a-code-route.aspx</link><pubDate>Wed, 08 Jul 2009 20:35:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7143731</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7143731</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/07/08/a-callback-function-is-always-trigered-at-last-in-a-code-route.aspx#comments</comments><description>&lt;P&gt;A segment of javascript code :&lt;/P&gt;&lt;PRE class=csharpcode&gt; &lt;SPAN class=kwrd&gt;function&lt;/SPAN&gt; getValue() {
          &lt;SPAN class=kwrd&gt;var&lt;/SPAN&gt; rel = &lt;SPAN class=kwrd&gt;null&lt;/SPAN&gt;;
          CustomService.GetValueFromServer(
          &lt;SPAN class=kwrd&gt;function&lt;/SPAN&gt;(result) {
              rel = result;
          }
          );

          &lt;SPAN class=kwrd&gt;return&lt;/SPAN&gt; rel;
      }

    &lt;SPAN class=kwrd&gt;var&lt;/SPAN&gt; myValue = getValue();&lt;/PRE&gt;
&lt;P&gt;CustomService is a "ScriptService" attributed c# webService class with a functional method "GetValueFromServer" supplying certain string value :&lt;/P&gt;&lt;PRE class=csharpcode&gt;[WebService(Namespace = &lt;SPAN class=str&gt;"http://tempuri.org/"&lt;/SPAN&gt;),
WebServiceBinding(ConformsTo=WsiProfiles.BasicProfile1_1),
ScriptService]
&lt;SPAN class=kwrd&gt;public&lt;/SPAN&gt; &lt;SPAN class=kwrd&gt;class&lt;/SPAN&gt; CustomService : WebService
{
    [WebMethod]
    &lt;SPAN class=kwrd&gt;public&lt;/SPAN&gt; &lt;SPAN class=kwrd&gt;string&lt;/SPAN&gt; GetValueFromServer()
    {
        &lt;SPAN class=kwrd&gt;return&lt;/SPAN&gt; &lt;SPAN class=str&gt;"Yes I have got it."&lt;/SPAN&gt;;
    }
}
        &lt;/PRE&gt;
&lt;P&gt;Then , guess what will happen to "myValue" ? Will it be "Yes I have got it" ?? No , its value will be null after assignation.&lt;/P&gt;
&lt;P&gt;The reason is revealed in article subject. CALLBACK is always occuring at the very end.&lt;/P&gt;
&lt;P&gt;If you are not quit familar with client invocation of webservice please reference the official link :&lt;/P&gt;&lt;A href="http://www.asp.net/AJAX/Documentation/Live/Tutorials/ConsumingWebServicesWithAJAXTutorial.aspx" mce_href="http://www.asp.net/AJAX/Documentation/Live/Tutorials/ConsumingWebServicesWithAJAXTutorial.aspx"&gt;Calling Web Services from Client Script in ASP.NET AJAX&lt;/A&gt; 
&lt;P&gt;Now let me explain the short route.&lt;/P&gt;
&lt;P&gt;"var myValue = getValue()" invokes getValue() method , where following steps execute subsequently : 
&lt;OL&gt;
&lt;LI&gt;"rel" is initialized with null&lt;/LI&gt;
&lt;LI&gt;CustomService.GetValueFromServer() is called. But no js code excutes at this time at client! Note the function() is just a CALLBACK on a successful condition! As subject reveals , it will not be ruded in at this time , meaning "result" is not passed to rel.&lt;/LI&gt;
&lt;LI&gt;"rel" , a variable not passed with any value and staying null , is returned.&lt;/LI&gt;
&lt;LI&gt;Consequently , "myValue" only get a null value.&lt;/LI&gt;
&lt;LI&gt;Eventually , the "onSucceed" callback function is fired ! Whatever happens in it , it loses the chance to provide client an expected value.&lt;/LI&gt;&lt;/OL&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7143731" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/ajax/default.aspx">ajax</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/ScriptService/default.aspx">ScriptService</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/callback/default.aspx">callback</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/webservice/default.aspx">webservice</category></item><item><title>Exception: The mapping of interface member IMetaEntity.Url is not supported</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/06/25/exception-the-mapping-of-interface-member-imetaentity-url-is-not-supported.aspx</link><pubDate>Thu, 25 Jun 2009 18:06:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7134249</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7134249</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/06/25/exception-the-mapping-of-interface-member-imetaentity-url-is-not-supported.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;Though&amp;nbsp;"Url" is an "LinqToSql" generated&amp;nbsp;property and strictly map to a database field &amp;nbsp;the exeption still yields when where clause is written as&lt;/P&gt;
&lt;P mce_keep="true"&gt;from item in db.GetTable&amp;lt;T&amp;gt; &lt;/P&gt;
&lt;P mce_keep="true"&gt;where item.Url = "&lt;A href="http://xxxxxx/"&gt;http://xxxxxx&lt;/A&gt;" &lt;/P&gt;
&lt;P mce_keep="true"&gt;select item;&lt;/P&gt;
&lt;P mce_keep="true"&gt;Solution:&amp;nbsp; such writting should be modified as :&amp;nbsp; item.Url.Equals( "&lt;A href="http://xxxxxx/"&gt;http://xxxxxx&lt;/A&gt;" )&lt;/P&gt;
&lt;P mce_keep="true"&gt;Then the exception is avoided.&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;Why ?&amp;nbsp; I do not know. Someone points out that it is Linq Team's mistake ...&amp;nbsp;&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7134249" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/LinqToSql/default.aspx">LinqToSql</category></item><item><title>GallaryServerPro:Could not load file or assembly 'ComponentArt.Web.UI' or one of its dependencies</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/05/29/gallaryserverpro-could-not-load-file-or-assembly-componentart-web-ui-or-one-of-its-dependencies.aspx</link><pubDate>Fri, 29 May 2009 16:16:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7101903</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7101903</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/05/29/gallaryserverpro-could-not-load-file-or-assembly-componentart-web-ui-or-one-of-its-dependencies.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;It is because the block action conducted by Mcafee !&lt;/P&gt;
&lt;P mce_keep="true"&gt;Access Protection -&amp;gt; Common Maximum Protecttion -&amp;gt; Prevent creation of new excutable files in the Windows Folder&lt;/P&gt;
&lt;P mce_keep="true"&gt;Unblock it !&amp;nbsp; Then everything is OK.&lt;/P&gt;
&lt;P mce_keep="true"&gt;For just a web application I need make some risk ...&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7101903" width="1" height="1"&gt;</description></item><item><title>How to config Gallary Server Pro..</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/05/29/how-to-config-gallary-server-pro.aspx</link><pubDate>Fri, 29 May 2009 08:01:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7101580</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7101580</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/05/29/how-to-config-gallary-server-pro.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;1&amp;nbsp; set "web_sqlserver_3.5.config" as the "true" config file ..&lt;/P&gt;
&lt;P mce_keep="true"&gt;2&amp;nbsp; Network Service Permission on some folders &lt;/P&gt;
&lt;P mce_keep="true"&gt;3&amp;nbsp; gs/config/gallaryserverpro.config :&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&amp;nbsp; showErrorDetails="true"/"false"&amp;nbsp;&amp;nbsp;&amp;nbsp; 根据情况可以设置&lt;/P&gt;
&lt;P mce_keep="true"&gt;4&amp;nbsp; Bin 文件夹： &lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&amp;nbsp; delete&amp;nbsp; Sql.Lite.Dll !&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&amp;nbsp; AjaxControlToolkit ,&amp;nbsp;&amp;nbsp; EnterpriseLibery&amp;nbsp;&amp;nbsp; dll update to newest version !&lt;/P&gt;
&lt;P mce_keep="true"&gt;5&amp;nbsp; delete gallary server pro logo!&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; seek "&amp;lt;div class="gsp_addtopmargin5 gsp_footer"&amp;gt;" then posit to &lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&amp;nbsp; GallaryPage.AddGspLogo( HtmlTextWriter )&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&amp;nbsp; comment codes in it !&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7101580" width="1" height="1"&gt;</description></item><item><title>All about new FTP publishing service 7.5  for IIS7</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/05/27/all-about-new-ftp-publishing-service-for-iis7.aspx</link><pubDate>Thu, 28 May 2009 01:47:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7099225</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7099225</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/05/27/all-about-new-ftp-publishing-service-for-iis7.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;Currently I study &amp;nbsp;the IIS-customized FTP service toolkit and find it a little hard.&amp;nbsp; I list some notes here for memorandum and share.&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Introduction:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;A href="http://learn.iis.net/page.aspx/310/what-is-new-for-microsoft-and-ftp-75/" target=_blank mce_href="http://learn.iis.net/page.aspx/310/what-is-new-for-microsoft-and-ftp-75/"&gt;What Is New for Microsoft and FTP 7.5?&lt;/A&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Installation &amp;amp; Creation:&lt;/STRONG&gt; &lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Authentication &amp;amp; Authorization&amp;nbsp;:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;Ideally ,&amp;nbsp; IIS Manager Authentication is a good choice for a public per-user based&amp;nbsp;FTP access environment.&lt;/P&gt;
&lt;P mce_keep="true"&gt;Prerequisite :&lt;/P&gt;
&lt;P mce_keep="true"&gt;Grant&amp;nbsp;specific permissions to config files'&amp;nbsp;directory !&lt;/P&gt;
&lt;P mce_keep="true"&gt;%SystemDrive%\Windows\System32\inetsrv\config&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;
&lt;P mce_keep="true"&gt;----&amp;nbsp; \administration.config&lt;/P&gt;
&lt;P mce_keep="true"&gt;----&amp;nbsp; \redirection.config&lt;/P&gt;
&lt;P mce_keep="true"&gt;Or else IISWMSVC_AUTHENTICATION_UNABLE_TO_READ_CONFIG error might occur when&amp;nbsp;a client is trying to login FTP site.&amp;nbsp;&amp;nbsp; &lt;/P&gt;
&lt;P mce_keep="true"&gt;1.&amp;nbsp; Choose "Windows credentials or IIS Manager credentials" in the "IIS Credentials"&amp;nbsp; chrome of "Management Service" section.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;IIS-HOME--&amp;gt;Management--&amp;gt;Management Service ( the Management Service should be pre-installed through "Add roles-features" operation ).&amp;nbsp; What is worth mentioning is the Managment Service is unecessary to start for FTP purpose.&lt;/P&gt;
&lt;P mce_keep="true"&gt;2.&amp;nbsp; Add/Remove &amp;nbsp;User for an IIS-root.&amp;nbsp; A new user could only be added in the "IIS User Manager" section. This&amp;nbsp;section inhabits an IIS' root and&amp;nbsp;takes fundamental responsibility for "adding-removing" accounts.&lt;/P&gt;
&lt;P mce_keep="true"&gt;4.&amp;nbsp; For an "FTP Authentication" section ( locating at&amp;nbsp;the FTP Site root ) ,&amp;nbsp; we add a "custom provider"&amp;nbsp;: "IIS Manager Auth". We enable it and disable other two built-in providers ( based on windows authentication mechanism )&amp;nbsp;&amp;nbsp;to ensure&amp;nbsp;the&amp;nbsp;whole FTP site pure IIS-based authentication policy.&lt;/P&gt;
&lt;P mce_keep="true"&gt;3.&amp;nbsp; Make permission plan for&amp;nbsp;an FTP Root site&amp;nbsp;. For those IIS-owned users, only the allowed are possible to access corresponding FTP site. Do this&amp;nbsp;via "IIS Manager Permissions" panel.&amp;nbsp; In the panel we can click "Allow user" action , select "IIS Manager" and enter a target username . Success of such operation means current location is basically visible to the account.&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;5.&amp;nbsp; For each node of&amp;nbsp;FTP Site , we should&amp;nbsp;&amp;nbsp;cautiously configurate it's authorization . ( FTP Authorization )&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;For more information please check : &lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;A href="http://learn.iis.net/page.aspx/321/configure-ftp-with-iis-70-manager-authentication/" target=_blank mce_href="http://learn.iis.net/page.aspx/321/configure-ftp-with-iis-70-manager-authentication/"&gt;Configure FTP with IIS 7.0 Manager Authentication&lt;/A&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Isolation :&lt;/STRONG&gt; &lt;/P&gt;
&lt;P mce_keep="true"&gt;If you want a client automatically directed to his/her&amp;nbsp;own directory once logining&amp;nbsp;FTP site with his&amp;nbsp;credentials info&amp;nbsp;, meanwhile prevented from home&amp;nbsp;directory , you are supposed to pick up&amp;nbsp;:&lt;/P&gt;
&lt;P mce_keep="true"&gt;Isolate Users -&amp;gt; User name directory ( diable global virtual directries )&lt;/P&gt;
&lt;P mce_keep="true"&gt;in the FTP User Isolation section ( situated at FTP site root control panel )&lt;/P&gt;
&lt;P mce_keep="true"&gt;For how to create iis-user-based /&amp;nbsp;username-based virtual directory which is internally adapted&amp;nbsp;assigned isolation policy ,&amp;nbsp;refer to :&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;A href="http://learn.iis.net/page.aspx/305/configuring-ftp-75-user-isolation/" target=_blank mce_href="http://learn.iis.net/page.aspx/305/configuring-ftp-75-user-isolation/"&gt;Configuring FTP 7.5 User Isolation&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;STRONG&gt;Port &amp;amp; Firewall Configuration :&lt;/STRONG&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;Important! Outer users are blocked from FTP site unless firewall is configged by following the guide :&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;SPAN style="WIDOWS: 2; TEXT-TRANSFORM: none; TEXT-INDENT: 0px; BORDER-COLLAPSE: separate; FONT: 22px Verdana; WHITE-SPACE: normal; ORPHANS: 2; LETTER-SPACING: normal; COLOR: rgb(0,0,0); WORD-SPACING: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0" class=Apple-style-span&gt;&lt;A href="http://learn.iis.net/page.aspx/309/configuring-ftp-firewall-settings/" target=_blank mce_href="http://learn.iis.net/page.aspx/309/configuring-ftp-firewall-settings/"&gt;Configuring FTP Firewall Settings&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&lt;SPAN style="WIDOWS: 2; TEXT-TRANSFORM: none; TEXT-INDENT: 0px; BORDER-COLLAPSE: separate; FONT: 22px Verdana; WHITE-SPACE: normal; ORPHANS: 2; LETTER-SPACING: normal; COLOR: rgb(0,0,0); WORD-SPACING: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0" class=Apple-style-span&gt;Note the "firewall support" in IIS-root / FTP Site-root sections.&lt;/SPAN&gt;&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7099225" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/iis7/default.aspx">iis7</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/IIS+Manager+Authentication/default.aspx">IIS Manager Authentication</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/FTP/default.aspx">FTP</category></item><item><title>Server installation Issue</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/05/25/server-installation-issue.aspx</link><pubDate>Mon, 25 May 2009 15:34:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7097464</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7097464</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/05/25/server-installation-issue.aspx#comments</comments><description>&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;After installation of windows server 2008 sp2 to a intel-S3000AH motherboard based server ,&amp;nbsp; two "?" display in the Device Manager window.&amp;nbsp;&amp;nbsp; PCI serial prot / XXXX ( forget it ). &lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;Then follow the link :&lt;/P&gt;
&lt;P mce_keep="true"&gt;
&lt;TABLE border=0 cellSpacing=0 cellPadding=0&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD class=bodycopy&gt;&lt;STRONG&gt;&lt;A href="http://www.intel.com/support/motherboards/server/s3000ah/sb/cs-025601.htm" target=_blank mce_href="http://www.intel.com/support/motherboards/server/s3000ah/sb/cs-025601.htm"&gt;Two unknown devices under Microsoft Windows* Device manager&lt;/A&gt;&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;According to the guide I tried such download from&amp;nbsp;&lt;A href="http://downloadcenter.intel.com/Filter_Results.aspx?strTypes=all&amp;amp;ProductID=2569&amp;amp;OSFullname=All+Operating+Systems&amp;amp;lang=eng&amp;amp;strOSs=All&amp;amp;submit=Go%21" mce_href="http://downloadcenter.intel.com/Filter_Results.aspx?strTypes=all&amp;amp;ProductID=2569&amp;amp;OSFullname=All+Operating+Systems&amp;amp;lang=eng&amp;amp;strOSs=All&amp;amp;submit=Go%21"&gt;S3000AH-related&amp;nbsp;miscellaneous downloading page&lt;/A&gt; :&lt;/P&gt;
&lt;P mce_keep="true"&gt;Driver /&amp;nbsp; Intel® On Board Network Driver for Windows&lt;/P&gt;
&lt;P mce_keep="true"&gt;Download , unzip ,&amp;nbsp;running &amp;nbsp;"Auto Update" against the wield device , everything is OK.&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7097464" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/s3000AH/default.aspx">s3000AH</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/windows+server+2008/default.aspx">windows server 2008</category></item><item><title>Scrutinize keyboard event handler syntax in different browers</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/05/13/javascript-keyboard-event-syntax-compatible-with-firefox.aspx</link><pubDate>Wed, 13 May 2009 19:26:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7085257</guid><dc:creator>zc0000</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7085257</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/05/13/javascript-keyboard-event-syntax-compatible-with-firefox.aspx#comments</comments><description>Source : &lt;PRE class=csharpcode&gt; &lt;SPAN class=kwrd&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN class=html&gt;script&lt;/SPAN&gt; &lt;SPAN class=attr&gt;type&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;="text/javascript"&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;&amp;gt;&lt;/SPAN&gt;

        &lt;SPAN class=kwrd&gt;function&lt;/SPAN&gt; keyEventArgsChecking(e) {

            &lt;SPAN class=kwrd&gt;var&lt;/SPAN&gt; msg = &lt;SPAN class=str&gt;""&lt;/SPAN&gt;;

            &lt;SPAN class=rem&gt;// The "event" declaration will cause error in FireFox .  We should use window.event instead.&lt;/SPAN&gt;
            &lt;SPAN class=rem&gt;// In other words , code line below can be avoid in IE context.&lt;/SPAN&gt;
            &lt;SPAN class=kwrd&gt;var&lt;/SPAN&gt; &lt;SPAN class=kwrd&gt;event&lt;/SPAN&gt; = window.&lt;SPAN class=kwrd&gt;event&lt;/SPAN&gt;;

            &lt;SPAN class=kwrd&gt;if&lt;/SPAN&gt; (&lt;SPAN class=kwrd&gt;event&lt;/SPAN&gt;) {
                msg = &lt;SPAN class=str&gt;"Checking is under IE / Google Chrome &amp;lt;hr&amp;gt;"&lt;/SPAN&gt;;

                msg +=
                &lt;SPAN class=kwrd&gt;new&lt;/SPAN&gt; Array(
                &lt;SPAN class=str&gt;"window.event is valid in such context. window.event property : "&lt;/SPAN&gt;,
                &lt;SPAN class=str&gt;"type : "&lt;/SPAN&gt; + &lt;SPAN class=kwrd&gt;event&lt;/SPAN&gt;.type,
                &lt;SPAN class=str&gt;"keyCode : "&lt;/SPAN&gt; + &lt;SPAN class=kwrd&gt;event&lt;/SPAN&gt;.keyCode,
                &lt;SPAN class=str&gt;"srcElement : "&lt;/SPAN&gt; + &lt;SPAN class=kwrd&gt;event&lt;/SPAN&gt;.srcElement
                ).join(&lt;SPAN class=str&gt;"&amp;lt;br&amp;gt;"&lt;/SPAN&gt;);

            }
            &lt;SPAN class=kwrd&gt;else&lt;/SPAN&gt;
                msg = &lt;SPAN class=str&gt;"Checking is under FireFox"&lt;/SPAN&gt;;

            msg +=
            &lt;SPAN class=str&gt;"&amp;lt;hr&amp;gt;"&lt;/SPAN&gt; +
             &lt;SPAN class=kwrd&gt;new&lt;/SPAN&gt; Array(
                &lt;SPAN class=str&gt;"current argument's property : "&lt;/SPAN&gt;,
                &lt;SPAN class=str&gt;"type : "&lt;/SPAN&gt; + e.type,
                &lt;SPAN class=str&gt;"keyCode : "&lt;/SPAN&gt; + e.keyCode,
                &lt;SPAN class=str&gt;"which : "&lt;/SPAN&gt; + e.which,
                &lt;SPAN class=str&gt;"srcElement : "&lt;/SPAN&gt; + e.srcElement,
                &lt;SPAN class=str&gt;"target : "&lt;/SPAN&gt; + e.target
                ).join(&lt;SPAN class=str&gt;"&amp;lt;br&amp;gt;"&lt;/SPAN&gt;);

            divMsg.innerHTML = msg;

        }


    &lt;SPAN class=kwrd&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN class=html&gt;script&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;&amp;gt;&lt;/SPAN&gt;

    Type some text to trigger key event:
    &lt;SPAN class=kwrd&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN class=html&gt;ul&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;&amp;gt;&lt;/SPAN&gt;
        &lt;SPAN class=kwrd&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN class=html&gt;li&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;&amp;gt;&lt;/SPAN&gt;
            &lt;SPAN class=kwrd&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN class=html&gt;input&lt;/SPAN&gt; &lt;SPAN class=attr&gt;type&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;="text"&lt;/SPAN&gt; &lt;SPAN class=attr&gt;onkeypress&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;="keyEventArgsChecking(event)"&lt;/SPAN&gt; &lt;SPAN class=kwrd&gt;/&amp;gt;&lt;/SPAN&gt;
            Pass built-in "event" object as argument&lt;SPAN class=kwrd&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN class=html&gt;li&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;&amp;gt;&lt;/SPAN&gt;
        &lt;SPAN class=kwrd&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN class=html&gt;li&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;&amp;gt;&lt;/SPAN&gt;
            &lt;SPAN class=kwrd&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN class=html&gt;input&lt;/SPAN&gt; &lt;SPAN class=attr&gt;type&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;="text"&lt;/SPAN&gt; &lt;SPAN class=attr&gt;onkeypress&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;="keyEventArgsChecking(this)"&lt;/SPAN&gt; &lt;SPAN class=kwrd&gt;/&amp;gt;&lt;/SPAN&gt;
            Pass source trigger object as argument&lt;SPAN class=kwrd&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN class=html&gt;li&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;&amp;gt;&lt;/SPAN&gt;
        &lt;SPAN class=kwrd&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN class=html&gt;li&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;&amp;gt;&lt;/SPAN&gt;
            &lt;SPAN class=kwrd&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN class=html&gt;input&lt;/SPAN&gt; &lt;SPAN class=attr&gt;type&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;="text"&lt;/SPAN&gt; &lt;SPAN class=attr&gt;onkeypress&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;="keyEventArgsChecking(foo)"&lt;/SPAN&gt; &lt;SPAN class=kwrd&gt;/&amp;gt;&lt;/SPAN&gt;
            Pass an arbitrary object as argument ( error ) &lt;SPAN class=kwrd&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN class=html&gt;li&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;&amp;gt;&lt;/SPAN&gt;
    &lt;SPAN class=kwrd&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN class=html&gt;ul&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;&amp;gt;&lt;/SPAN&gt;
    &lt;SPAN class=kwrd&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN class=html&gt;div&lt;/SPAN&gt; &lt;SPAN class=attr&gt;id&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;="divMsg"&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;&amp;gt;&lt;/SPAN&gt;
    &lt;SPAN class=kwrd&gt;&amp;lt;/&lt;/SPAN&gt;&lt;SPAN class=html&gt;div&lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;&amp;gt;&lt;/SPAN&gt;&lt;/PRE&gt;Effect: 
&lt;DIV class=dynamic&gt;
&lt;SCRIPT type=text/javascript&gt;

        function keyEventArgsChecking(e) {

            var msg = "";

            // The "event" declaration will cause error in FireFox .  We should use window.event instead.
            // In other words , code line below can be avoid in IE context.
            var event = window.event;

            if (event) {
                msg = "Checking is under IE / Google Chrome &lt;hr&gt;";

                msg +=
                new Array(
                "window.event is valid in such context. window.event property : ",
                "type : " + event.type,
                "keyCode : " + event.keyCode,
                "srcElement : " + event.srcElement
                ).join("&lt;br&gt;");

            }
            else
                msg = "Checking is under FireFox";

            msg +=
            "&lt;hr&gt;" +
             new Array(
                "current argument's property : ",
                "type : " + e.type,
                "keyCode : " + e.keyCode,
                "which : " + e.which,
                "srcElement : " + e.srcElement,
                "target : " + e.target
                ).join("&lt;br&gt;");

            divMsg.innerHTML = msg;

        }


    &lt;/SCRIPT&gt;
Type some text to trigger key event: 
&lt;UL&gt;
&lt;LI&gt;&lt;INPUT onkeypress=keyEventArgsChecking(event)&gt;&lt;/INPUT&gt; Pass built-in "event" object as argument&lt;/LI&gt;
&lt;LI&gt;&lt;INPUT onkeypress=keyEventArgsChecking(this)&gt;&lt;/INPUT&gt; Pass source trigger object as argument&lt;/LI&gt;
&lt;LI&gt;&lt;INPUT onkeypress=keyEventArgsChecking(foo)&gt;&lt;/INPUT&gt; Pass an arbitrary object as argument ( error ) &lt;/LI&gt;&lt;/UL&gt;
&lt;DIV id=divMsg&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;B&gt;Conclusion:&lt;/B&gt; 
&lt;P&gt;From above scripts we can draw these conclusions:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Neither "event" nor "this" is necessary to be passed as eventHandler's argument In IE/Chrome , because we can get keyboardEvent object directly from window.event property ( window.event.keyCode ...) and access event source via window.event.srcElement ( in Chrome window.event.target is also valid ). If "event" passed to "e" , "e" is identical to "window.event" ; If "this" passed to "e" , "e" is identical to "window.event.srcElement(target)".&lt;/LI&gt;
&lt;LI&gt;Although eighter "event" or "this" is valid eventhandler argument in FireFox , passing "this" could only access the event source object whereas lose the thread attaching keyboard event itself ! We will be at a loss to find which key is pressed and unable to further route logic anymore. In such case , "event" is a highly recommended choice for it is the only entry to access keyboard event object . Source can be picked through "event.target" property. &lt;/LI&gt;
&lt;LI&gt;Groogle Chrome ( GC ) is "most compatible" when comparing with IE / FF. Some key properties are all accessable to GC. Let's take the event object as example. Blank cell means the property behaves normally in corresponding brower. 
&lt;TABLE&gt;
&lt;CAPTION&gt;event ( window.event in IE ) properties' accessing situation in different browers&lt;/CAPTION&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD&gt;&lt;/TD&gt;
&lt;TD&gt;IE&lt;/TD&gt;
&lt;TD&gt;GC&lt;/TD&gt;
&lt;TD&gt;FF&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD&gt;keyCode&lt;/TD&gt;
&lt;TD&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;/TD&gt;
&lt;TD&gt;always 0&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD&gt;which&lt;/TD&gt;
&lt;TD&gt;undefined&lt;/TD&gt;
&lt;TD&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD&gt;srcElement&lt;/TD&gt;
&lt;TD&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;/TD&gt;
&lt;TD&gt;undefined&lt;/TD&gt;&lt;/TR&gt;
&lt;TR&gt;
&lt;TD&gt;target&lt;/TD&gt;
&lt;TD&gt;undefined&lt;/TD&gt;
&lt;TD&gt;&lt;/TD&gt;
&lt;TD&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7085257" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/javascript/default.aspx">javascript</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/Firefox/default.aspx">Firefox</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/eventhandler/default.aspx">eventhandler</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/keyup/default.aspx">keyup</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/keypress/default.aspx">keypress</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/keydown/default.aspx">keydown</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/keyboard/default.aspx">keyboard</category></item><item><title>$(document).ready() and pageLoad() are not the same!</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/05/13/document-ready-and-pageload-are-not-the-same.aspx</link><pubDate>Wed, 13 May 2009 09:37:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7084798</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7084798</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/05/13/document-ready-and-pageload-are-not-the-same.aspx#comments</comments><description>Refer to: &lt;BR&gt;&lt;A href="http://encosia.com/2009/03/25/document-ready-and-pageload-are-not-the-same/" target=_blank mce_href="http://encosia.com/2009/03/25/document-ready-and-pageload-are-not-the-same/"&gt;$(document).ready() and pageLoad() are not the same!&lt;/A&gt; &lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7084798" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/Asp.net+3.5/default.aspx">Asp.net 3.5</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/ScriptManager/default.aspx">ScriptManager</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/ajax/default.aspx">ajax</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/jquery/default.aspx">jquery</category></item><item><title>WebRequest some site url meeting : The remote server returned an error: (403)</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/05/05/webrequest-some-site-url-meeting-the-remote-server-returned-an-error-403.aspx</link><pubDate>Tue, 05 May 2009 21:01:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7074369</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7074369</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/05/05/webrequest-some-site-url-meeting-the-remote-server-returned-an-error-403.aspx#comments</comments><description>&lt;P class=blogTitle&gt;Avoid (403) Forbidden errors when using HttpWebRequest &lt;/P&gt;
&lt;DIV&gt;
&lt;DIV class=blogBody&gt;I had an error when tried to open the page &lt;FONT color=#008000 size=2&gt;&lt;A href="http://www.lycos.com/" target=_blank&gt;http://www.lycos.com/&lt;/A&gt;&lt;/FONT&gt;&amp;nbsp;&lt;SPAN class=maintext&gt; using &lt;A href="http://blogs.msdn.com/smourier/archive/2003/06/04/8265.aspx" target=_blank&gt;&lt;U&gt;&lt;FONT color=#800080&gt;HtmlAgilityPack&lt;/FONT&gt;&lt;/U&gt;&lt;/A&gt;&amp;nbsp;from my ASP.NET application.&lt;BR&gt;The exception was &lt;FONT color=#ff0000 size=1&gt;System.Net.WebException: The underlying connection was closed: The server committed an HTTP protocol violation.&lt;/FONT&gt;&lt;BR&gt;When I tried to reproduce the problem using the test function &lt;FONT size=2&gt;GetLycosUrl&lt;/FONT&gt;&amp;nbsp;(see below) from WinForms application, it throwed the different &lt;FONT color=#ff0000&gt;&lt;FONT size=+0&gt;(&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT size=+0&gt;&lt;FONT size=+0&gt;403) f&lt;/FONT&gt;&lt;/FONT&gt;orbidden error&lt;/STRONG&gt;&lt;/FONT&gt;. After some research I &lt;A href="http://dotnetjunkies.com/WebLog/afontes/archive/2004/10/15/28726.aspx" target=_blank&gt;found&lt;/A&gt; that&amp;nbsp;&lt;FONT color=#ff0000&gt;&lt;FONT size=1&gt; HTTP protocol violation&amp;nbsp; &lt;/FONT&gt;&lt;FONT color=#4e4d45&gt;&lt;FONT size=1&gt;can be ignored, if you specify &lt;STRONG&gt;UseUnsafeHeaderParsing=true&lt;/STRONG&gt; &lt;/FONT&gt;&lt;FONT color=#000000 size=1&gt;in the configuration file. HttpWebRequest.&lt;STRONG&gt;UseUnsafeHeaderParsing&amp;nbsp;&lt;/STRONG&gt;&amp;nbsp;property is internal and read-only and can't be changed for particular instance of HttpWebRequest. &lt;BR&gt;It is also suprising that WinForms application does not raise &lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT size=1&gt;&lt;FONT color=#ff0000&gt;HTTP protocol violation&amp;nbsp;&lt;/FONT&gt;&lt;FONT color=#4e4d45&gt;error even the debugger shows that &lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT color=#000000&gt;&lt;FONT size=1&gt;&lt;STRONG&gt;UseUnsafeHeaderParsing&amp;nbsp;&lt;/STRONG&gt;&amp;nbsp;=false.&lt;BR&gt;Now&amp;nbsp;the question was why lycos send me back lycos send me back &lt;FONT color=#ff0000&gt;(&lt;STRONG&gt;&lt;FONT size=+0&gt;&lt;FONT size=+0&gt;403) f&lt;/FONT&gt;&lt;/FONT&gt;orbidden error.&lt;BR&gt;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT color=#4e4d45&gt;With the help of &lt;A href="http://www.fiddlertool.com/fiddler/" target=_blank&gt;Fiddler&lt;/A&gt; I identified that the differense between IE and call from my application is&amp;nbsp;&lt;FONT size=2&gt;UserAgent&lt;/FONT&gt;&amp;nbsp;header. If header will be provided, valid&amp;nbsp;page will be returned from &lt;STRONG&gt;&lt;FONT size=2&gt;&lt;FONT size=1&gt;HttpWebRequest&lt;/FONT&gt;.&lt;/FONT&gt;GetResponse.&lt;BR&gt;To&amp;nbsp;make&amp;nbsp;&amp;nbsp;&lt;/STRONG&gt;&lt;A href="http://blogs.msdn.com/smourier/archive/2003/06/04/8265.aspx" target=_blank&gt;&lt;U&gt;&lt;FONT color=#800080&gt;HtmlAgilityPack&lt;/FONT&gt;&lt;/U&gt;&lt;/A&gt;&amp;nbsp;more robust the change in &lt;FONT size=2&gt;HtmlWeb.&lt;/FONT&gt;&lt;FONT size=2&gt;Get(Uri uri, &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;string&lt;/FONT&gt;&lt;FONT size=2&gt; method, &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;string&lt;/FONT&gt;&lt;FONT size=2&gt; path, HtmlDocument doc) is required.&lt;BR&gt;&lt;/FONT&gt;&lt;FONT face="Courier New"&gt;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;FONT face="Courier New"&gt;&lt;SPAN class=comment&gt;&lt;FONT color=#1f661f&gt;//MNF 26/5/2005 Some web servers (e.g. http://www.lycos.com/) return 403 forbidden error unless UserAgent is specified&amp;nbsp;&lt;BR&gt;&amp;nbsp;&amp;nbsp;//so let's say it's IE6&amp;nbsp;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;req&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;.&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;UserAgent&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;=&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=string&gt;&lt;FONT color=#cc1f1f&gt;"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0; .NET CLR 1.1.4322)"&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc face="Courier New"&gt;;&amp;nbsp;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=comment&gt;&lt;FONT color=#1f661f face="Courier New"&gt;//alternatively&amp;nbsp;&amp;nbsp;it can be changed in PreRequest event handler &lt;/FONT&gt;&lt;BR&gt;&lt;/SPAN&gt;&lt;BR&gt;The function to test&amp;nbsp;&lt;FONT color=#cc1f1f face="Courier New"&gt;&lt;A href="http://www.lycos.com/" target=_blank&gt;www.lycos.com&lt;/A&gt; &lt;/FONT&gt;url is the following:&lt;BR&gt;&lt;SPAN class=html&gt;&lt;SPAN class=default&gt;&lt;FONT face="Courier New"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;FONT face="Courier New"&gt;&lt;SPAN class=comment&gt;&lt;FONT color=#1f661f&gt;//Add using to the top of file &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;//&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;using System.Net; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;//&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;using System.Diagnostics; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;private void GetLycosUrl&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face="Courier New"&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;() &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&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;&amp;nbsp;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;string url&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;=@&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=string&gt;&lt;FONT color=#cc1f1f&gt;"http://www.lycos.com/"&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face="Courier New"&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;; &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;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;HttpWebRequest request &lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;= (&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;HttpWebRequest&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;) &lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;WebRequest&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;.&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;Create&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;(&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;url&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc face="Courier New"&gt;); &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;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;FONT face="Courier New"&gt;&lt;SPAN class=comment&gt;&lt;FONT color=#1f661f&gt;//the following line is critical, otherwise (403) forbidden error error will be returned &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;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;request&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;.&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;UserAgent&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;=&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=string&gt;&lt;FONT color=#cc1f1f&gt;"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0; .NET CLR 1.1.4322)"&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc face="Courier New"&gt;; &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;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;&lt;FONT face="Courier New"&gt;try &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;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;FONT face="Courier New"&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;{ &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;HttpWebResponse response &lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;= (&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;HttpWebResponse&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;) &lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;request&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;.&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;GetResponse&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face="Courier New"&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;(); &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;} &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;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;catch &lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;(&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;Exception exc&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face="Courier New"&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;) &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;{ &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;Debug&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;.&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;Assert&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;(&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;false&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;,&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;exc&lt;/SPAN&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;.&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;ToString&lt;/SPAN&gt;&lt;/FONT&gt;&lt;FONT face="Courier New"&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc&gt;()); &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;throw&lt;/SPAN&gt;&lt;/FONT&gt;&lt;SPAN class=keyword&gt;&lt;FONT color=#1f1fcc face="Courier New"&gt;; &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;} &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;} &lt;/FONT&gt;&lt;BR&gt;&lt;/SPAN&gt;&lt;SPAN class=default&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7074369" width="1" height="1"&gt;</description></item><item><title>Running Web Applications on Windows Vista with IIS 7.0 and Visual Studio</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/05/05/running-web-applications-on-windows-vista-with-iis-7-0-and-visual-studio.aspx</link><pubDate>Tue, 05 May 2009 12:51:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7073785</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=7073785</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/05/05/running-web-applications-on-windows-vista-with-iis-7-0-and-visual-studio.aspx#comments</comments><description>&lt;P&gt;To access local IIS Web sites, you must run Visual Studio in the context of an administrator account. By default, Windows runs applications in a limited-rights user account even when you are logged on to the computer as an administrator. &lt;/P&gt;
&lt;H3 class=procedureSubHeading&gt;To run Visual Studio with administrative permissions in Windows Vista&lt;/H3&gt;
&lt;DIV class=subSection&gt;
&lt;OL&gt;
&lt;LI&gt;
&lt;P&gt;In Windows Vista, click &lt;SPAN class=label&gt;&lt;STRONG&gt;Start&lt;/STRONG&gt;&lt;/SPAN&gt;, click &lt;SPAN class=label&gt;&lt;STRONG&gt;All Programs&lt;/STRONG&gt;&lt;/SPAN&gt;, and then locate Visual Studio. &lt;/P&gt;&lt;/LI&gt;
&lt;LI&gt;
&lt;P&gt;Right-click &lt;SPAN class=label&gt;&lt;STRONG&gt;Microsoft Visual Studio&lt;/STRONG&gt;&lt;/SPAN&gt;, and then click &lt;SPAN class=label&gt;&lt;STRONG&gt;Run as administrator&lt;/STRONG&gt;&lt;/SPAN&gt;. &lt;/P&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;/DIV&gt;
&lt;P mce_keep="true"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For more details refer to :&lt;/P&gt;
&lt;DIV class=title&gt;&lt;A href="http://msdn.microsoft.com/en-us/library/aa964620.aspx" target=_blank mce_href="http://msdn.microsoft.com/en-us/library/aa964620.aspx"&gt;Running Web Applications on Windows Vista with IIS 7.0 and Visual Studio&lt;!----&gt;&lt;/A&gt;&lt;/DIV&gt;&lt;!--Content type: Devdiv1. Transform: orcas2mtps.xslt.--&gt;
&lt;DIV id=mainSection&gt;
&lt;DIV id=mainBody&gt;
&lt;P&gt;&lt;!----&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7073785" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/Visual+Studio+2008/default.aspx">Visual Studio 2008</category><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/Vista/default.aspx">Vista</category></item><item><title>Url-resolving issue in a "Cacheable-Sharable" UserControl</title><link>http://weblogs.asp.net/atlaszhu/archive/2009/03/13/url-resolving-issue-in-a-quot-cacheable-sharable-quot-usercontrol.aspx</link><pubDate>Fri, 13 Mar 2009 15:52:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:6957418</guid><dc:creator>zc0000</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://weblogs.asp.net/atlaszhu/rsscomments.aspx?PostID=6957418</wfw:commentRss><comments>http://weblogs.asp.net/atlaszhu/archive/2009/03/13/url-resolving-issue-in-a-quot-cacheable-sharable-quot-usercontrol.aspx#comments</comments><description>&lt;P&gt;ResolveUrl and ResolveClientUrl are two methods that help to resolve "~/" prefixed format path to client-browser-usable format. Normally , they take the same effective and just differ in the terminate displaying . Then assuming such a control-holser environment : a UserControl which is designed to shared by a batch of pages; Initially we still find no problems by using either ResolveUrl or ResolveClientUrl to treat url issues in the control , however , if we "cache" the UserControl , mark it with "shared" attribute, and adopt it into an application of multiple pages in different directories , a problem is possible to occur .&lt;/P&gt;
&lt;P&gt;Lets assume such a senario :&lt;/P&gt;When building a website , the "top" part is commonly shared by all pages and always displays statically . Considering slightly memory save and performance leverage , a developer encalpusulates such part into a userControl named "Top.ascx" and put it in the same folder of site "Default.aspx" page . Also , considering "different folders' sharing" problem , html links cannot simply use their client url format , so each link in the "Top" usercontrol is re-producted like this : 
&lt;P&gt;&amp;lt;a href="~/User/Default.aspx" runat="server"&amp;gt;User Panel&amp;lt;/a&amp;gt;&lt;/P&gt;
&lt;P&gt;Note that each server control uses "ResolveClientUrl" to process its Url property value. So the final resolved url may look like "User/Default.aspx" , "../User/Default.aspx" , "../../User/Default.aspx" , based on different host page's location, but never "/User/Default.aspx" ( application runs in root-site ) or "/Application/User/Default.aspx" ( application runs in virtual path "/Application" ) . The latter two results are generated by "ResolveUrl" method. &lt;/P&gt;
&lt;P&gt;After link-processing work we add OutputCache declaration to the UserControl to make it cacheable:&lt;/P&gt;
&lt;P&gt;&amp;lt;%@ OutputCache &lt;SPAN style="COLOR: red; font-bold: weight"&gt;Shared="true"&lt;/SPAN&gt; Duration="100000" VaryByParam="none" %&amp;gt;&lt;/P&gt;
&lt;P&gt;Then put it on the top postion of each "form" in aspx page ( I neglect the "registeration" declaration ) : &lt;/P&gt;&amp;lt;form runat="server"&amp;gt;... &lt;BR&gt;&amp;lt;cc1:Top runat="server" /&amp;gt; &lt;BR&gt;...&lt;BR&gt;&amp;lt;/form&amp;gt;&lt;BR&gt;
&lt;P&gt;So far , without red-highlighted attribute , there is still no problem when using the control : the "top.ascx" will be correctly and correspondingly processed for the first time visiting of its host page ; however , in such case , each different page owns an independent copy of the same version UserControl in the memory : we enhance the page-processing performance but waste memory . We want "one copy , all share" against the immutable top part. So the existence of "Shared=true" lies in here : one copy of "top part" control is eventually cached in the memory and sharable for all pages inhabiting current application . &lt;/P&gt;
&lt;P&gt;Then , the combination of "cache" and "share" operation against a UserControl may bring up following problem : &lt;/P&gt;
&lt;P&gt;If we first visit the root default page : /Default.aspx ( in my assumption the Top.ascx also in the root folder of current application ), since it is the first time visiting , Top.acsx will be processed and the "html anchor" control will return an "User/Default.aspx" relative path string; Then we visit an other page : /News/NewsList.aspx ; since the "top.ascx" has been sharely-cached , "top.ascx" UserControl put in the "newslist.aspx" will not process again ; its content directly pours to response stream from memory instead ! So as for the example we still get the link "User/Default.aspx" in the "/News/" context! If user click the link , he will be led to "/News/User/Default.aspx" ---- an nonexistent location ! &lt;/P&gt;
&lt;P&gt;The solution is simple : In such context , do not use server control and "~/" grammar to set url ; Just use primitive html code and inline method "ResolveUrl" to set url , like this : &lt;/P&gt;&amp;lt;a href='&amp;lt;%=ResolveUrl("~/User/Default.aspx")%&amp;gt;' &amp;gt;User Panel&amp;lt;/a&amp;gt; 
&lt;P&gt;To see an actual , lively sample please visit : &lt;/P&gt;&lt;A href="http://www.china-mc.com/" target="_blank" &gt;http://www.china-mc.com/&lt;/A&gt; ( &lt;A href="http://www.china-mc.com/" target="_blank" &gt;China Medical Center&lt;/A&gt; ) 
&lt;P&gt;For purpose of performace optimization and memory saving , I design several OutputCache strategies for different part of different pages with the help of UserControl. As you see , the top navigation part and bottom are obvious samples. And the url issue is found in the progress. It is simple to overcome ; However , the conception behind curtain ---- "shared outputCache" is important. &lt;/P&gt;
&lt;P&gt;This large portal medical web site is built upon asp.net 3.5 SP1 framework and a lot of fashion technologies overwhelmed by many aspects such as LINQ To Sql , WebForm-based Routing , Control Development , Partial Cache Control Design &amp;amp; Strategy , Global Layout Control , MS Ajax-JQuery etc. are applied to the site. It is an infant. I am the developer &amp;amp; operator of this site and is willing to share my development experience &amp;amp; interesting content relating to my site. &lt;/P&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6957418" width="1" height="1"&gt;</description><category domain="http://weblogs.asp.net/atlaszhu/archive/tags/asp.NET+3.5+routing+outputcache+version/default.aspx">asp.NET 3.5 routing outputcache version</category></item></channel></rss>