Knowledge Base

BUG: Visual InterDev 6.0 or Visual J++ 6.0 Crash When You Edit HTML with RDS Objects

Article ID: 200683

Article Last Modified on 8/16/2005


APPLIES TO


This article was previously published under Q200683

SYMPTOMS

You may encounter "random crashing" with Visual InterDev 6.0 or Visual J++ 6.0 when you edit Active Server Pages (ASP) or HTML pages that have HTML <OBJECT> references to RDS DataControl objects (CLSID:BD96C556-65A3-11D0-983A-00C04FC29E33). Here is a sample error message:
Devenv.exe Exception: access violation (0xc0000005), Address: <address>

CAUSE

The crash occurs if you use the <PARAM> tag to specify the RDS DataControl parameters (Server, Connect, SQL), as in the following example:
  <OBJECT classid="CLSID:BD96C556-65A3-11D0-983A-00C04FC29E33"
    ID=Authors height=0 width=0
    PARAM name=Server value="http://myserver"
    PARAM name=Connect value="dsn=pubs;uid=***;pwd=***;"
    PARAM name=SQL value="SELECT * FROM Authors">
  </OBJECT>
				
The development shell for Visual InterDev 6.0 and Visual J++ 6.0 attempts to access the RDS data at design time if the <PARAM> tags for the Server, Connect, and SQL properties are specified as a part of the <OBJECT> tag. This behavior exposes a bug in Microsoft Data Access Components version 2.0, which closes an asynchronous thread and then later tries to reference the closed thread, causing the crash.

RESOLUTION

To work around this bug, specify the Server, Connect, and SQL properties in script, as in the following example:
  <OBJECT classid="CLSID:BD96C556-65A3-11D0-983A-00C04FC29E33"
    ID=Authors height=0 width=0>
 </OBJECT>
  <SCRIPT Language=VBScript>
    Authors.Server  = "http://myserver"
    Authors.Connect = "dsn=pubs;uid=***;pwd=***"
    Authors.SQL     = "SELECT * FROM Authors"
    Authors.Refresh
  </SCRIPT>
				
The code will function at run time and avoid the bug at design time.

STATUS

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

Keywords: kbbug kbfix KB200683