Tip #40: Did you know…How to scope master pages?

Master page is a  template page that can be used to create a consistent layout for your application. First you create a master page to define the look & feel of the application and then you create the content pages that contains the content. You can attach these content pages to the master page at…

7

Tip #39: Did you know… How to cancel a remote web operation in Visual Studio 2008?

In VS2005, when you connected to an FTP or FrontPage server, the IDE would not let you intervene to cancel the operation.  In VS2008, during most any operation that has you connecting to a remote source via FTP or FrontPage Server Extensions, you can hit the “Esc” key, and the IDE should cancel or give…

5

Tip #38: Did you know… How to use Failed Request Tracing to trace Rewrite Rules?

IIS7.0 Failed Request Tracing (FRT) is a powerful troubleshooting tool for request-processing failures. More details regarding FRT and how to enable it can be be found here. Once the failed request tracing is enabled for your site, do the following to trace rewrite rules: Double click on "Failed Request Tracing Rules" icon to get to…

3

Tip #37: Did you know…How to organize usings?

Overtime C# source code files may have unnecessary & unorganized using directives. Visual Studio IDE organize using options can help you to unclutter the source code. To organize the C# code right click anywhere inside the code editor, select Organize usings. Select Remove Unused Usings to remove any using directives that are not used in…

3

Tip #36: Did you know… How to manage pilot or beta program for your site using Application Request Routing in IIS7.0?

Won’t it be cool if you can target and route appropriate users of your site to your pilot/beta/new looking site based on user’s profile. This may help you in managing select users who have previously signed for pilot program and redirect them to new looking web site and gather feedback. This is a very typical…

2

Tip #35: Did you know…How to add Intellisense from script libraries for JS files?

Here is an example to add intellisense for JS files in VS 2008. So, you have two Javascript files Jscript1.js with the following code function validateForm() {} and Jscript2.js (wherein you want current JScript file to show intellisense including objects & functions declared in Jscript1.js)Now to add intellisense, from the solution explorer drag drop Jscript1.js…

2

Tip #33: Did you know… How to create Nested Master Pages using VS 2008?

VS 2008 and VWD 2008 both support Nested Master Pages which means you can have a Base Master page which would cater to the whole site and then you can further customize these Base Master Pages. Here is how you do it: 1. Create a BaseMasterPage.master for the base look: First we need to create…

5

Tip #32: Did you know… How to easily create your own project templates?

Visual Studio makes it very easy to create item and project templates with the Export Template Wizard. Open the wizard by selecting Export Template… from the file menu. Note: For this tip I am using the Jobs Site Starter Kit. After selecting Export Template… the Export Template Wizard will appear.   For this tip we…

5

Tip #31: Did you know… How to have user friendly URL using IIS 7.0 URL Rewrite module?

It’s always good to have friendly URL so that people visiting your site find it easier to remember. Asking your user to remember http://www.contoso.com/article.aspx?id=342&title=URL-Rewrite-Walkthrough for URL Rewrite walkthrough is not the nicest thing to do. Won’t it be cool if user can be provided with URL like http://www.contoso.com/article/342/URL-Rewrite-Walkthrough. This indeed resonates better and is much…

3