FIX: Error When You Use Page Object to Navigate URL with Spaces (193999)



The information in this article applies to:

  • Microsoft Visual InterDev 6.0

This article was previously published under Q193999

SYMPTOMS

When you use a Page Object Design-Time Control (DTC) in a page, and you insert a thisPage.navigateURL method call using a URL that contains spaces, you receive the following error message:
HTTP Error 400
400 Bad Request

Due to malformed syntax, the request could not be understood by the server. The client should not repeat the request without modifications.

RESOLUTION

Use the %20 character instead of spaces. For example, change "ASP Page 1.asp" to "ASP%20Page%201.asp".

STATUS

Microsoft has confirmed that this is a bug in the Microsoft products that are listed at the beginning of this article.

This bug was corrected in Microsoft Visual Studio 6.0 Service Pack 5. For additional information about Visual Studio service packs, click the following article numbers to view the articles in the Microsoft Knowledge Base:

194022 INFO: Visual Studio 6.0 Service Packs, What, Where, Why

194295 HOWTO: Tell That a Visual Studio Service Pack Is Installed

To download the latest Visual Studio service pack, visit the following Microsoft Web site:

MORE INFORMATION

Steps to Reproduce Behavior

  1. Create a new Web project in Visual InterDev.
  2. Create two Active Server Pages (ASP) pages named "ASP Page 1.asp" and "ASP Page 2.asp," and make sure that they exist in the same folder.
  3. On "ASP Page 2.asp," add a page object DTC and a DTC command button.
  4. Using the scripting outline, add an "onclick" handler for the button.
  5. In the handler, add the following code:
          thisPage.navigateURL("ASP Page 1.asp")
    					
  6. View "ASP Page 2," and click the command button.

Modification Type:MinorLast Reviewed:12/12/2005
Keywords:kbBug kbCtrl kberrmsg kbfix kbRemoteProg kbScript KB193999