Article ID: 185697 - Last Review: August 27, 2007 - Revision: 3.3 How To Use the AddObject Method of the Script ControlThis article was previously published under Q185697 On This PageSUMMARY
This article describes the AddObject method of the Microsoft Script control
and discusses object visibility.
MORE INFORMATION
The Microsoft Scripting control provides the AddObject method to allow the
host application to expose an object model to the script code. Objects
added this way are implicitly assumed to be safe for scripting and are not
affected by the UseSafeSubset property.
The AddObject method has the following arguments:
Name: The name the script code can use to access the object.
Object: The object to be made available (late bound) to the script.
AddMembers: This is an optional argument. Default value is False.
If True, the methods and properties are available as
global functions and variables.
If False, the methods and properties are only available via
fully qualified object.member syntax.
Microsoft provides programming examples for illustration only, without warranty either expressed or implied, including, but not limited to, the implied warranties of merchantability and/or fitness for a particular purpose. This article assumes that you are familiar with the programming language being demonstrated and the tools used to create and debug procedures. Example
REFERENCES
Sct10en.exe is the executable file that contains the MSScript.ocx. When the
executable is run MSScript.ocx is installed. The Scriptcontrol can be
downloaded from the following Web site:
http://www.microsoft.com/technet/scriptcenter/default.mspx
(http://www.microsoft.com/technet/scriptcenter/default.mspx)
(c) Microsoft Corporation 1998, All Rights Reserved. Contributions by Malcolm Stewart, Microsoft Corporation APPLIES TO
| Article Translations
|
Back to the top
