Skip to content

Commit 9077ae2

Browse files
[doc] adjust documentation for NewObject
1 parent 595ff5a commit 9077ae2

2 files changed

Lines changed: 4 additions & 61 deletions

File tree

src/DocChinese/VFPDocs.xml

Lines changed: 2 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -6327,38 +6327,10 @@
63276327
指定从中创建新类或对象的类或对象。
63286328
</param>
63296329
<param name="cModule">
6330-
指定包含由cClassName指定的类或对象的.vcx文件或X#程序(.prg、.fxp、.mpr、.app、.exe等)。
6331-
默认为.vcx文件。如果指定程序文件,必须包含扩展名。
6332-
<note name="注意">
6333-
类库可以有别名。要指定带有别名的类库中的类或对象,
6334-
请包含类库别名,后跟句点和对象名称。<br/>
6335-
当类存储在程序文件(.prg)中时,尽可能指定已编译的程序名(.fxp)。
6336-
这确保从正确的类定义文件加载类。
6337-
</note>
6338-
如果省略cModule,或为空字符串或空值,X#按以下顺序搜索类或对象:
6339-
<list type="bullet">
6340-
<item>X#基类。</item>
6341-
<item>当前程序中的类。</item>
6342-
<item>使用Set CLASSLIB打开的类库。</item>
6343-
<item>使用Set PROCEDURE打开的过程文件中的类。</item>
6344-
<item>X#程序执行链中的类。</item>
6345-
<item>如果Set OLEOBJECT为ON,则搜索OLE注册表。</item>
6346-
</list>
6330+
此参数在 X# 中未使用,仅为兼容 Visual FoxPro 而包含。
63476331
</param>
63486332
<param name="cInApplication">
6349-
指定包含您用cModule指定的.vcx文件的X#应用程序(.exe或.app)。
6350-
必须为应用程序包含扩展名。如果省略cModule,或cInApplication为空字符串或空值,则忽略cInApplication。<br/>
6351-
如果要使用cInApplication参数,必须为cModule指定.vcx文件的名称。
6352-
不能传递.prg文件或已编译程序(.fxp)的名称。
6353-
</param>
6354-
<param name="0">
6355-
指定实例化类或对象时不执行类或对象中的任何事件或方法代码。
6356-
此功能在运行时应用程序中不受支持。<br/>
6357-
父类的所有子类或对象也会被实例化。子类或对象中的事件或方法代码不会被执行。<br/>
6358-
此选项提供了查看类或对象结构的能力(例如,使用AMembers()函数),
6359-
而无需在类设计器或窗体设计器中打开类或对象。<br/>
6360-
注意,绝不应执行类或对象中的代码 - 不支持代码执行,可能会使X#不稳定。
6361-
您不应显式调用事件或方法,或设置属性。设置属性可能会调用Access和Assign方法。
6333+
此参数在 X# 中未使用,仅为兼容 Visual FoxPro 而包含。
63626334
</param>
63636335
<param name="eParameter1">
63646336
指定传递给类或对象的Init事件过程的可选参数。

src/Docs/VFPDocs.xml

Lines changed: 2 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -6282,39 +6282,10 @@
62826282
Specifies the class or object from which the new class or object is created.
62836283
</param>
62846284
<param name="cModule">
6285-
Specifies a .vcx file or X# program (.prg, .fxp, .mpr, .app, .exe, and so on) containing the class or object specified with cClassName.
6286-
The default is a .vcx file. If you specify a program file, you must include an extension.
6287-
<note name="Note">
6288-
A class library can have an alias. To specify a class or object from a class library with an alias,
6289-
include the class library alias followed by a period and the object name.<br/>
6290-
When possible, specify the compiled program name (.fxp) when a class is stored in a program file (.prg).
6291-
This ensures that the class is loaded from the proper class definition file.
6292-
</note>
6293-
If cModule is omitted, or is the empty string or the null value, X# searches for the class or object in the following order:
6294-
<list type="bullet">
6295-
<item>X# base classes.</item>
6296-
<item>Classes in the current program.</item>
6297-
<item>Class libraries opened with Set CLASSLIB.</item>
6298-
<item>Classes in procedure files opened with Set PROCEDURE.</item>
6299-
<item>Classes in the X# program execution chain.</item>
6300-
<item>The OLE registry if Set OLEOBJECT is ON.</item>
6301-
</list>
6285+
This parameter is not used in X#. It is included for compatibility with Visual FoxPro.
63026286
</param>
63036287
<param name="cInApplication">
6304-
Specifies the X# application (.exe or .app) containing the .vcx file you specify with cModule.
6305-
You must include an extension for the application. CInApplication is ignored if cModule is omitted,
6306-
or if cInApplication is the empty string or the null value.<br/>
6307-
If you want to use the cInApplication parameter, you must specify the name of .vcx file for cModule.
6308-
You cannot pass the name of a .prg file or compiled program (.fxp).
6309-
</param>
6310-
<param name="0">
6311-
Specifies that the class or object is instantiated without executing any of the event or method code in the class or object.
6312-
This feature is not supported in runtime applications.<br/>
6313-
All child classes or objects of the parent class are also instantiated. The event or method code in the child class or object isn't executed.<br/>
6314-
This option is provides the ability to view the structure of a class or object (with the AMembers( ) Function,
6315-
for example) without opening the class or object in the Class or Form Designer.<br/>
6316-
Note that code in the class or object should never be executed - code execution is not supported and can make X# unstable.
6317-
You should never explicitly call an event or method, or set properties. Setting properties can call Access and Assign methods.
6288+
This parameter is not used in X#. It is included for compatibility with Visual FoxPro.
63186289
</param>
63196290
<param name="eParameter1">
63206291
Specifies optional parameters that are passed to the Init event procedure for the class or object.

0 commit comments

Comments
 (0)