Microsoft Active Server Pages Release Notes


Active Server Pages (ASP) is a feature of the following Web server releases:

You can also install and use Active Server Pages with Microsoft Personal Web Server version 1.0a on Windows® 95 to create ASP applications for deployment on Internet Information Server.

This document addresses the following issues pertaining to ASP:

Installation Issues
Where is the Product Documentation?
Known Issues
Maintaining Browscap.ini
Using Notepad with .Asp Files
Server-Side Includes Issues
Additional Changes to Internet Information Server and Peer Web Services
How to Obtain the North American Version of Microsoft Windows NT Service Pack 2

Installation Issues

This section discusses issues with which you should be familiar prior to installing ASP.

Minimum Disk Space

You should have a minimum of 30 megabytes of free disk space in order to install ASP.

Microsoft Windows NT and Microsoft Windows 95 Web Servers

Before you install ASP on a computer running Microsoft Windows NT or Microsoft Windows 95, you must have already installed one of the following Microsoft Web servers:

Stop Applications and Services That Use ODBC Prior To Installing ASP

Before you install ASP, be sure to stop all applications and services that might use ODBC, including Microsoft SQL Server and Microsoft Access.

Installing ASP on a Windows NT Backup Domain Controller

If you installed Microsoft Internet Information Server as part of installing Microsoft Windows NT Server, and you made your computer a Backup Domain Controller during Windows NT setup, you will receive an error message when you install ASP. To successfully install ASP under these conditions:

  1. Select Active Server Pages Uninstall from the Microsoft Internet Server (Common) Program Group in order to remove ASP.
  2. Reinstall IIS.
  3. Reinstall ASP.

Installing Microsoft VM for Java

ASP supports server components written in Java. To run Java server components, you must first install Microsoft VM for Java™ on your Web server. VM is available for download from www.microsoft.com, from the following locations:

VM is also included in Windows NT version 4.0 Service Pack 2 and later.

Database Access Component Include Files

If you plan to use the ADO constants defined in the include files Adovbs.inc and Adojavas.inc (for VBScript and JScript, respectively), be sure to install the Adventure Works sample site. These files are located in the Aspsamp\Samples directory, which is installed in the \Inetpub directory by default.

Where is the Product Documentation?

The Active Server Pages documentation is in HTML format and is installed with the product. After you have installed Active Server Pages, you can view the documentation by choosing Active Server Pages Roadmap from your Web server’s program group. From the Roadmap you can also view the Adventure Works sample Web site, which demonstrates many of the features of Active Server Pages scripting and is an excellent source of sample code. You can also view the Roadmap by typing the following address: http://yourserver/iasdocs/aspdocs/roadmap.asp.

The documentation Roadmap requires either Internet Explorer version 3.0 or later or a browser that supports frames. You will get the best results with Internet Explorer.

Known Issues

This section identifies issues that are not fully addressed in ASP documentation.

Using NTFS to Prevent Access to an .Asp File

If you are using NTFS, and you want to prevent access to an .asp file, perform the following procedure:

  1. With the file to which you want to prevent access selected, select File.
  2. Click Properties.
  3. Click the Security tab.
  4. Click File Permissions.
  5. In the Type of Access window, select No Access.

Note   If you select Special Access in Step 5 above, be sure that the Read permission is not enabled.

Using NTFS to Secure an Application

To fully secure an ASP application, be sure to set NTFS file permissions for the appropriate user or group on your application’s Global.asa file. If your Global.asa includes commands that return information to the browser and you do not secure Global.asa, that information will be returned to the browser, even if the application’s other files are secured.

Using Secure Sockets Layer with ASP

This section discusses issues of which you should be aware when using Secure Sockets Layer (SSL) with ASP.

Including Files

If you include a file that resides in an SSL-enabled virtual root from a file that resides in an unsecured virtual root, SSL is not applied to the included file. Thus, to ensure that SSL is applied, be sure that including as well as included files reside in SSL-enabled virtual roots.

Client Authentication

If you are using SSL client authentication, you should be aware of the sequence of events involved in this process:

  1. A browser sends an HTTP request for a file.
  2. If the client does not have a valid certificate and a client certificate is required (as configured through administration), access is denied and authentication ends. If the client has a valid certificate, the SSL connection is established and authentication continues.
  3. The Web server performs HTTP logon authentication and access control checking.
  4. If logon and access control checking complete successfully, the Web server processes the file and sends it to the browser.

Naming Restrictions For Virtual Roots With Sessions

If you use sessions, and a virtual root name begins with and entirely contains another virtual root name, then session state may incorrectly span applications residing in these virtual roots. For example, the name /root1 begins with and contains the name /root, so using roots of these names would result in this situation. To avoid this situation, be sure that no virtual root name begins with and entirely contains another virtual root name.

Using Microsoft SQL Server With Session-Scope Objects

If the only database you use with ASP is Microsoft SQL Server—that is, you never use Microsoft Access (.mdb) files with ASP—and you create instances of the Database Access Component that you store in the Session object, you can enhance performance by changing the threading model for Database Access Component instances from Apartment to Both in the registry. To change from Apartment to Both, double-click Makefree.bat in the \Program Files\Common Files\System\Ado folder.

To reverse this process, (that is, to change the threading model from Both to Apartment) double-click Makeapt.reg in the \Program Files\Common Files\System\Ado folder.

Note    We recommend that you not store instances of the Database Access Component in the Session object. For information about recommended ways of handling Web-based database connections, see Connection Pooling in Component Reference.

Connection Pooling

This section discusses issues related to connection pooling.

Connection Pooling Disabled by Default

Connection Pooling in Component Reference incorrectly states that connection pooling is enabled by default in ASP. Connection pooling is now disabled by default. You can enable connection pooling by setting the registry entry, StartConnectionPool, to 1. See Configuring Registry Entries in Scripting Guide for more information.

Connection Pooling and Microsoft Access

Unless you install Microsoft Windows NT Service Pack 2 (SP2) or later, using Microsoft Access with connection pooling enabled may cause system failures when shutting down IIS. Therefore, if you use Microsoft Access, and you have not installed SP2 or later, then you should not enable connection pooling.

Connection Pooling and Microsoft SQL Server

If you have installed SP2 or later, or if the only database you use with ASP is Microsoft SQL Server—that is, you never use Microsoft Access (.mdb) files with ASP—then enabling connection pooling will result in enhanced performance. You can enable connection pooling by setting the registry entry, StartConnectionPool, to 1. See Configuring Registry Entries in Scripting Guide for more information.

ASP Treatment of Stored Objects Not Marked “Both”

Performance Issues in Scripting Guide incorrectly states that, when storing objects in the Session and Application objects:

...unless the object you store is marked “both,” ASP treats the application or session containing this object as “single-threaded.”

This should instead read:

...unless the object you store is marked “both,” ASP treats the application or session containing this object as “apartment-threaded.”

Improving Performance by Disabling CheckForNestedVroots

By default, ASP checks for new virtual roots that are nested within other virtual roots on every request. This check causes performance degradation. If you are running on a stable production system (that is, you are not creating new virtual roots), then setting the Registry entry CheckForNestedVroots to 0 will improve the performance of your server. However, setting this Registry entry to 0 will also cause nested virtual roots created while the system is running to not see the Global.asa file. See Configuring Registry Entries in Scripting Guide for more information.

Running Out of Virtual Memory

Under heavy load, a Web server running ASP might exhaust the virtual memory allocated to it. This allocation is based on the MemFreeFactor registry entry. MemFreeFactor is set to 50 by default.

A value of 0 causes Active Server Pages not to cache any memory; in this case, you are likely to run out of virtual memory relatively quickly. A value of 100 or greater causes ASP to cache substantially more memory. This means you are less likely to run out of virtual memory, but other applications will have less memory available to them.

If your are running a Web server dedicated to serving .Asp files, and it is exhausting virtual memory, you may want to increase the value of MemFreeFactor to 100 or greater.

If, on the other hand, serving .asp files is not placing heavy demand on your Web server and you do not want to allocate memory away from other applications, do not adjust the value of MemFreeFactor.

See Configuring Registry Entries in Scripting Guide for more information.

Global.asa Issues

This section discusses issues having to do with Global.asa files.

Global.asa Must Reside in Virtual Root

Using the Global.asa File in Scripting Guide and Global.asa Reference indicate that a Global.asa file must reside in the root directory of an ASP-based application. This root must also be a virtual root.

Updating a File Included by Global.asa

Updating a file that is included by Global.asa does not restart sessions. Therefore, objects stored in the Application object are not reset. To restart sessions, save the Global.asa file.

Registering Components

If you have trouble registering components on Windows NT Server and Windows NT Workstation, you may be using the wrong version of Regsvr32. Please use the version installed by default in the directory C:\Winnt\System32\Inetsrv\ASP\Cmpnts.

Recompiling Server Components That Use Response.BinaryWrite

The Response.BinaryWrite now requires a variant of type VT_ARRAY|VT_UI1 instead of a pointer to a SafeArray as a parameter. Thus, if you have existing ActiveX server components that use Response.BinaryWrite, you must recompile these components with the new header file. Refer to IResponse::BinaryWrite in Creating Components for ASP for more information.

Note   Components that do not use Response.BinaryWrite are not affected by this change; you need not recompile them.

Server.MapPath and Relative Path Syntax

The following note, from Map Path in Object Reference, is incorrect:

Note   The path parameter can contain relative paths (../../Scripts/, for example) if the EnableParentPath registry setting is set to TRUE. This is the default setting.
The Server.MapPath method does not currently support the relative path syntax (.) or (..). For example, the following script command will not work:

<%= Server.MapPath("../MyDir/MyFile.txt") %>

SCRIPT_MAP Server Variable No Longer Exists

ServerVariables in Object Reference identifies SCRIPT_MAP as a server variable you can use with the Request object to obtain the base portion of a URL. This variable is no longer supported; use the URL variable, which also returns the base portion of the URL.

Using Microsoft Index Server With Microsoft Windows 95

Microsoft Index Server is not available for Windows 95. Thus, if you are running Windows 95 and you click the Search button from the ASP Roadmap, you will receive an error message.

Providing Unknown Scripting Language Causes Error

Specifying an unknown scripting language as the value of the DefaultScriptLanguage registry entry may cause the following error message:

http/1.0 500 server error
If you get this error, check the DefaultScriptLanguage registry entry. Make sure that you have supplied a valid language.

Using Microsoft JScript

To use JavaScript in your ASP files, use “JScript” as the language attribute of the <SCRIPT> tag. While “JavaScript” is supported for backward compatibility, mixing lines of script labeled “JScript” with lines of script labeled “JavaScript” will cause errors.

NCompass Billboard Control

The NCompass billboard control is only provided for Intel processors. This release does not include versions for the Alpha and PowerPC processors.

Database Access Component Issues

For performance and reliability reasons, we strongly recommend the use of Microsoft SQL Server for the deployment of production-quality Web applications. Although Active Server Pages works with any ODBC-compliant database, it has been extensively tested and is designed to work with Microsoft SQL Server. ASP also supports Microsoft Access as a valid data source. Although the sample Web site and examples in this release use Microsoft Access, we recommend that Microsoft Access be used solely for development purposes and not for production. Microsoft Access was designed as a single-user desktop database, and not for server use. When multiple, concurrent users make requests of a Microsoft Access database, unpredictable results may occur.

When using the Database Access component (ADO) on Windows 95 Personal Web Server and processing multiple requests, the system may stop responding. This is caused by a known problem with the shipping version of OLE on Windows 95. To resolve this situation, download and install the DCOM for Windows 95 update from http://www.microsoft.com/oledev/olemkt/oledcom/dcom95.htm.

Deleting a database record might cause a dynamic cursor to be lost. Further attempts to move the cursor will return unexpected results. To locate the cursor in the database, use the MoveFirst method to return to the first record, then relocate the cursor.

Deleting a row in a recordset and then trying to update the row at the same location may fail. If you need to update rows that may have been previously deleted on the current recordset, you should close the recordset and requery the data to be sure all rows are visible.

Null data can be stored as a column value in a database. The corresponding Visual Basic data type is Empty, which is equivalent to an empty string. Accessing a Null value and printing it will thus display nothing. To print a string for Null values, use a statement similar to the following:

<% If IsNull(RScatalog_item("ProductSize")) Then  
       Response.Write("ProductSize" & "is Null") %>

When using the Microsoft Access ODBC driver, setting the MaxRecords property of the RecordSet object does not limit the number of records returned.

Attempting to insert a record using the Recordset object with the AddNew method on a Microsoft Access database will fail if the database has been configured to do replication. To resolve this, include only the fields you need to insert a new value into in a SELECT statement when opening the RecordSet.

Using Out-of-Process Components

Out-of-process components (OLE components that run in a different process from ASP, such as Microsoft Excel), are disabled by default. We recommend that you not use out-of-process components, because using these components enables subsequent users of a component to inherit the original user’s security context. Using out-of-process components may also have a negative effect on performance. However, you can enable out-of-process components by changing the appropriate registry entry (AllowOutOfProcCmpnts) from 0 to 1. See Configuring Registry Entries in Scripting Guide for more information.

If you choose to use out-of-process components, you should have a thorough understanding of how to use them. As an example, you must use DCOM Configuration (dcomcnfg.exe) to set up a specific identity under which to run the component. Setting a specific identity avoids problems with different users inheriting each other's security contexts. For more information on out-of-process components, refer to the Microsoft Win32 Software Development Kit documentation. The OLE Programmer's Reference describes how to set up an identity for components.

Maintaining Browscap.ini

The Browscap.ini file lists property definitions for browsers that your script can check by using the Browser Capabilities component. This file will be updated as browser versions and capabilities change and may contain properties that are not documented in the Active Server Pages Component Reference. For example, the version of Browscap.ini included with this release of Active Server Pages contains a new property, Javaapplets, which specifies whether a browser supports Java applets.

Browscap.ini is installed, by default, in \Winnt\system32\inetsrv\ASP\Cmpnts. Visit http://www.microsoft.com/iis for updated versions of browscap.ini.

Using Notepad with .Asp Files

Here is a tip about using Notepad to create .asp files: In the Save or Save As dialog boxes, if the Save As Type box displays Text Documents (*.txt), the file name extension .txt is added to whatever you type in the File Name box. So, if you type Myfile.asp in the File Name box, the saved text file is actually named Myfile.Asp.txt. To avoid this, select All Files in the Save As Type list, or enclose the file name in quotation marks before saving.

Server-Side Includes Issues

This section discusses issues pertaining to Server-Side Includes (SSI).

SSI Support

This release of Internet Information Server and Peer Web Services includes enhancements to SSI syntax. For information on SSI, use your Web browser to open the SSI documentation at http://yourserver/iasdocs/aspdocs/ssi/isiall.htm.

Note   Personal Web Server on Windows 95 does not support the new SSI enhancements.

Refreshing Included Files

If you make a change to an included file, the change to the included file will automatically be reflected in output to a browser requesting the including file if the included file resides in a virtual root or one of its subdirectories. If the included file resides outside a virtual root or subdirectory thereof, the change will not be reflected in output to a browser until the Web server WWW service is restarted.

Additional Changes to Internet Information Server and Peer Web Services

This release of Internet Information Server and Peer Web Services contains two interface changes that are not documented in the Installation and Administration Guide for IIS and PWS.

Client Certificates

IIS and PWS now support the use of client certificates. When the client certificate option is enabled, the Web server requests a certificate to authenticate each client. You can also configure the Web server to require certificates before allowing access to the Web site. For more information, see Using Client Certificates in Scripting Guide.

Managing Internet Services from the File Properties Dialog Box

You can now stop, pause, and start the WWW, FTP, and Gopher services from the File Properties dialog box. In addition, you can create or modify virtual directories from the File Properties dialog box.

To administer a service:

  1. In Windows NT Explorer, right-click a folder.
  2. In the Properties dialog, click the Internet tab.
  3. Click Stopped, Paused, or Running to change the state of the service.
  4. Click OK.

To add or modify a virtual directory:

  1. In Windows NT Explorer, right-click a folder.
  2. In the Properties dialog, click the Internet tab.
  3. To modify the properties of an existing virtual directory, select the directory, click Properties, and then set the directory’s properties.
  4. To add a virtual directory, click Add and then set the directory’s properties.
For more information on adding or modifying virtual directory properties, see “Planning Your Content Directories” in your Web server’s Installation and Administration Guide.

How to Obtain the North American Version of Microsoft Windows NT Service Pack 2 (128 bit version)

There is no North American version of Microsoft Windows NT Service Pack 1a; however, the North American version of Service Pack 2 is available. Service Pack 2 includes all the fixes in Service Pack 1a and is compatible with Active Server Pages.

The North American (128-bit) version of Service Pack 2 is intended for distribution only in the United States and Canada. Export of the North American version of this service pack from the United States is regulated by the International Traffic in Arms Regulations (ITAR, 22 CFR 120-130) of the U.S. State Department, Office of Defense Trade Controls. A State Department license is required to export the North American version of Service Pack 2 outside the United States or Canada.

Microsoft will distribute the North American (128-bit) version of Service Pack 2 to U.S. or Canadian companies or persons for end-use in the U.S. or Canada only.

Ordering Information and Availability:
Customers in the 50 United States and Canada can order the the North American version of Service Pack 2 effective 12/15/96 for US $14.95 (CDN $20.95) plus customer service and handling charges of US $5 (CDN $7.50). Customers can order the product by phone.

Call (800) 370-8758; this 800 number is for customers calling in the U.S. and Canada.

Be sure to request Part Number 236-00711. Allow four weeks for delivery.


© 1996 Microsoft Corporation. All rights reserved.