This article was previously published under Q184739
This article has been archived. It is offered "as is" and will no longer be updated.
This article describes the procedure for obtaining the Script control.
On The Web
You can download the script control from the following Web site:
This page also provides a link to documentation on how to use the control.The file name you will receive is sct10en.exe.
NOTE: Registration is required before downloading this control.
Visual Basic 6.0
The Script control ships with Visual Basic 6.0; however, Visual Basic6.0 setup does not install the Script Control for you. The control islocated in the CD directory Common\Tools\VB\Script. To install thescript control, try the following steps:
Copy msscript.ocx to Windows\system or WinNT\system32.
Copy msscript.hlp and msscript.cnt to Windows\help or Winnt\help
Copy dispex.dll, jscript.dll and vbscript.dll to Windows\system or Winnt\system32. NOTE: If you have newer copies of these DLLs on your system, do notoverwrite them.
Register msscript.ocx using RegSvr32.exe. Example:
Using the Script Control
The script control installs both as an ActiveX control that you can placeon a form and as an ActiveX server that you can instantiate in code.
To make the control available to your project, click on the Projects Menuand select Components. This also makes the ActiveX server available.
To make just the ActiveX server available, click on the Projects Menu andselect References.
The help file for the script control contains limited sample code. Foradditional sample code, please see the following articles in the MicrosoftKnowledge Base:
184742 : HOWTO: Use the Script Control Error Object
184745 : HOWTO: Use Script Control Modules and Procedures Collections
184740 : HOWTO: Call Functions Using the Script Control
(c) Microsoft Corporation 1998, All Rights Reserved. Contributions byMalcolm Stewart, Microsoft Corporation
Microsoft Visual Basic 5.0 Learning Edition, Microsoft Visual Basic 6.0 Learning Edition, Microsoft Visual Basic 5.0 Professional Edition, Microsoft Visual Basic 6.0 Professional Edition, Microsoft Visual Basic 5.0 Enterprise Edition, Microsoft Visual Basic 6.0 Enterprise Edition, Microsoft Visual Basic 4.0 Standard Edition, Microsoft Visual Basic 4.0 Professional Edition, Microsoft Visual Basic 4.0 Enterprise Edition, Microsoft Visual Basic for Applications 5.0