Adds a new class or object to an object directly from a .vcx visual class library or program.
Syntax
Object.NEWOBJECT(cObjectName, cClassName [, cModule [, cInApplication
[, eParameter1, eParameter2, ...]]])
cObjectName
Specifies the name used to reference the newly added class or object.
cClassName
Specifies the class or object from which the new class or object is added.
cModule
Specifies a .vcx visual class library or Visual FoxPro program (.prg, .mpr, .app, .exe, and so on) containing the class or object specified with cClassName. The default is a .vcx visual class library; you must include an extension if you specify a program.
Note A class library can have an alias. To specify a class or object from a class library with an alias, include the class library alias followed by a period and the object name.
If cModule is omitted, or is the empty string or the null value, Visual FoxPro searches for the class or object in the following order:
cInApplication
Specifies the Visual FoxPro application (.exe or .app) containing the .vcx visual class library you specify with cClassLibName. You must include an extension for the application. CInApplication is ignored if cModule is omitted, or if cInApplication is the empty string or the null value.
eParameter1, eParameter2, ...
Specifies optional parameters that are passed to the Init event procedure for the class or object.
Remarks
The NEWOBJECT method allows you to add a new class or object to an object without opening a .vcx visual class library or procedure file.