IBM Support

Creating new ASP.NET Framework 1.x Web Applications while under source control with Rational ClearCase

Question & Answer


Question

What is the procedure for creating a new Microsoft® Visual Studio.NET version 2002, 2003 and 2005 web project (ASP.NET Web Application) using []Framework 1.x[] while under IBM® Rational® ClearCase® source control?

Cause

If you have already added an ASP.NET (Framework 1.x) solution or project to ClearCase source control, and wish to create a new project, follow the procedure below.

Note: If you have already added your ASP.NET (Framework 1.x) solution or project to ClearCase source control and you are having problems, review the Troubleshooting Tips at the end of the technote for assistance.

Add an existing ASP.NET Project to ClearCase:

If you need to add your existing ASP.NET project to source control, refer to the following technotes:


Add an existing VS.NET Project (Non-ASP.NET) to ClearCase:

If you need to add a VS.NET (non-ASP.NET) project to source control with ClearCase, refer to technote 1129529.

Add a New VS.NET Project to ClearCase.

Follow the instructions in the Online Help.included with ClearCase (Start > Programs > IBM Rational > IBM Rational ClearCase > Online Help > Rational ClearCase integrations with vendor products > Microsoft VS.NET)

Answer

Creating a New ASP.NET project in ClearCase:

  1. Create a VOB and view that you plan using with your ASP.NET (Framework 1.x) project.

    Note: Rational does not support serving ASP applications or webs in a dynamic view. Change request (RFE) RATLC00608173 has been submitted to add support for this functionality.

    Production deployment needs to be done through a snapshot view. Review Microsoft Knowledge Base Article 320268 for more details on the errors related to using a dynamic view to host ASP pages. Developing an ASP.NET project however, can be performed from a dynamic view.

    If the KB article has been applied successfully, attempts to use a Dynamic view with .NET IIS the following must be done:

    Do NOT used the Mapped Drive:
    M:\viewname\........

    Use a UNC path to the MVFS drive:
    \\view\<viewname>\......

    Where \\view is the literal name and <viewname> is the name of your view.


    The option A share located on another computer on the IIS admin console "Virtual Directory" tab, enter the user's account credentials (when you press the "connect as" button) and set the anonymous access account (on the "Directory Security" tab) to the same account.


    IMPORTANT: Open VS.NET and click Tools > Options and select Projects and Solutions from the Environment category. In the box labeled Visual Studio Projects Location, browse or type the view/VOB path. This should be done before continuing to step #2.

  2. Create a blank solution and store in the VOB.

    Note: This will create a solution folder in the VOB.

  3. In ClearCase Explorer or Windows Explorer create a folder inside the solution folder that will represent the name of your ASP.NET project or application.

  4. Start the Internet Information Services (IIS) Manager.

    Example: Click Start > Settings > Control Panel > Administration Tools > Internet Service Manager.

  5. Right-click on the desired Web Site and select Properties.

  6. Under the Home Directory tab, select A directory located on this computer and then browse to solution folder located in the VOB.

  7. Click Apply, and then OK. Close the Web Site properties.

    Note: You can also accomplish the mapping in IIS above using virtual directories.

    a. Right Click on the web site node and select create new virtual directory.

    b. The alias for the virtual directory should be the same name as the project folder you created in step #3 above.

    c. Browse or type in the path where the project folder lives when prompted. i.e. M:\view-tag\vob-tag\folder

    Note: The path to the content must go through the drive letter that is set in the ClearCase Control Panel under the MVFS tab. The default is "M". This must be set to the same value on all systems that will be accessing common projects and applications

    d. Enable all access rights when prompted. Read, run scripts, execute, write, and browse.

    e. Select finish.

  8. Open VS.NET

    Create a new ASP.NET Web Application project.
    During creation, select to add the project to the solution you created in step #2.
    Right click on the solution you created in step #2 and select Add New Project.
    Then select the type of VB Project you would like.

    Note: Make sure the URL path is pointing to http://localhost/project-name.

    IMPORTANT: If you create the project without creating the solution first, .NET will place the solution file in C:\Documents and Settings\{username}\MY Visual Studio Projects. When you try to add the project to source control .NET will look for the solution file in the VOB and when .NET can not find the solution file, .NET will abort the add to source control operation. The solution file must be placed in the VOB. The project folder must be placed inside the solution folder.

  9. In the VS.NET Solution Explorer, right-click on the Solution and select Add to Source Control...

  10. You may see a pop-up dialog box that says the following:

    You are attempting to add some File Share Web access projects to source control. If you continue, you will no longer be able to open these projects using Front Page Web Access.
    "

    Click Continue.

  11. You may then see another pop-up dialog box that says the following:

    The project <project_name> that you are adding to source control will be added to the same source control location as <project_name.sln>.  It overlaps this project in folder <<path>\view\vob\project_name>."  

    Click Continue.

  12. Once the project has been added to source control you are now ready to perform ClearCase Operations within the .NET IDE.

    Note: In order to Debug or Start without Debugging within the .NET IDE you will need to perform the following steps:
    • Set a breakpoint
    • Set your Start Page for the default.aspx file you are going to use as the start page.
    • Rebuild the solution.
    • Checkout the following files
      • Global.asax
      • Web.config
      • Default.aspx (start page)
    • Rebuild the solution.
    • Debug or Start Without Debugging.

This completes the steps required for the first view.



Troubleshooting Tips:

If you are experiencing permission issues or other unexpected results please consider the information below.

ASP.NET maintains its own cache information.

To clean up the cache go to C:\winnt\Microsoft.NET\Framework\<version number> and delete the Temporary ASP.NET Files folder.


Then cd into C:\winnt\Microsoft.NET\Framework\<version number> and run aspnet_regiis.exe -r

Note: aspnet_regiis.exe will rebuild mappings between IIS and ASP.NET.


If you receive an error Access is denied while trying to clean up the cache information do the following first.

  1. Stop IIS Services
  2. Go to Task Manager and End Process aspnet_up.exe
  3. End Process any other web service that is running ASP applications such as xpweb_debug or xpweb_application name.


DEBUGGING ASP.NET

In order to debug ASP.NET webs and applications, the user must be local administrator on the machine running IIS, as well as, a member of the local VS Developers group. This group is created during the installation of Visual Studio.NET.

Security Exception Error

Note: If you encounter the following error using virtual directories:



Security Exception Description: The application attempted to perform an operation not allowed by the security policy. To grant this application the required permission please contact your system administrator or change the application's trust level in the configuration file.

Exception Details: System.Security.SecurityException: Security error.

Source Error:

Line 30: private static bool __intialized = false; Line 31: Line 32: public Global_asax() { Line 33: if ((ASP.Global_asax.__intialized == false)) { Line 34: ASP.Global_asax.__intialized = true;



Review Microsoft Knowledge Base Article 320268 for more details.


[{"Product":{"code":"SSSH27","label":"Rational ClearCase"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"Integrations: Visual Studio.NET","Platform":[{"code":"PF033","label":"Windows"}],"Version":"2002.05.00;2003.06.00;7.0","Edition":"","Line of Business":{"code":"LOB45","label":"Automation"}},{"Product":{"code":"SSSH27","label":"Rational ClearCase"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"Integrations: Visual Studio.NET","Platform":[{"code":"","label":""}],"Version":"","Edition":"","Line of Business":{"code":"LOB45","label":"Automation"}}]

Document Information

Modified date:
16 June 2018

UID

swg21129588