newObjects-logo.gif (1024 bytes) newObjects ScriptManager2

Names and IDs

Product public name is newObjects ScriptManager2.
Program ID registered in the registry is newObjects.Scphost.ScpMan2.
Class ID of the component is: 6CEAA772-C22C-11d4-9979-0040332BA2EA
Threading model: both

Or

Program ID registered in the registry is newObjects.Scphost.ScpMan2.free.
Class ID of the component is: 75A6E42B-C882-42d4-A0B8-10D26C31F2F9
Threading model: free

Overview

newObjects.Scphost.ScpMan2 implements features needed to run Active Scripts. Component can be used in C++, Delphi or another projects where running external scripts can be useful. Also it can be used in the script languages to load and use external scripts (written in a different script language for example).

It ships with C++ helper library that contains several helper classes.These classes simplify the ActiveX component integration in a wide range of C++ projects. Of course you can avoid using them and use MSVC integrated COM support. But there are some cases in which compiler com support in MS Visual C++ is not enough flexible. As an example imagine that you must call functions defined in a script language. In the different scripts these functions may have variable count of arguments. Using the compiler COM support you will need a type library in order to generate the wrappers of these members. It is impossible to do this for the script with unknown structure. Using helper classes you can make dynamic calls to the script dispatch (functions defined in  the script) putting parameters and method names at run time.

Component supports event handling capabilities of the Microsoft Active Scripts. Additionally it supports an easy to use collection that holds interface pointers to the namespace objects given to the script.

Major part of the example code in the help file is written in script. C++ and ASP samples are in the samples directory of the distribution. To fully understand samples you will need basic knowledge of JScript and a little VBScript knowledge. Script samples in the help file are intended to show you how the component works. Component can be used from script and compiled languages but it is most useful for C++ programmers.

Threading model of the component is both thus it can be used in the Application and Session collections of the ASP applications (see ASP sample).

newObjects Copyright newObjects 2001-2005