PSS ID Number: 191979
Article Last Modified on 12/1/2003
The information in this article applies to:
- Microsoft Active Server Pages
- Microsoft Visual Basic Learning Edition for Windows 5.0
- Microsoft Visual Basic Professional Edition for Windows 5.0
- Microsoft Visual Basic Enterprise Edition for Windows 5.0
This article was previously published under Q191979
SYMPTOMS
When instantiating an ActiveX dynamic-link library (DLL) created with
Visual Basic 5.0 within an Active Server Page using the
Server.CreateObject, the following error may occur:
Error 'ASP 0115'
Unexpected error
/<VirtualRoot>/<ASPPage>
A trappable error occurred in an external object. The script cannot
continue running.
RESOLUTION
Apply Visual Studio 97 Service Pack 3 or later to Visual Basic 5.0 and
recompile the ActiveX DLL.
NOTE: Applying the latest version of the service pack will also apply fixes
from the previous versions of the service pack.
Use the following steps to recompile the ActiveX DLL in Visual Basic with
the latest service pack:
- Open the ActiveX DLL project.
- From the menu, select Project and go into <ProjectName> Properties where
<ProjectName> is the name of the ActiveX DLL project.
- In the <ProjectName> - Project Properties dialog box, click the General
tab.
- Go to the Threading Model frame and choose Apartment Threaded in the
combo box. Click OK.
- Recompile ActiveX DLL component and apply it back to the Web server.
- Register the ActiveX DLL component on the Web server using RegSvr32.exe,
if necessary.
NOTE: Apartment-model threading is the recommended threading model for
components that will be called by Active Server Pages.
Additional query words: viasp vb ActiveX dll asp kbdsi
Keywords: kbprb kbScript KB191979
Technology: kbASPsearch kbAudDeveloper kbVB500 kbVB500Search kbVBSearch kbZNotKeyword2 kbZNotKeyword6