Aide:ObjGet.txt

De Wiki AutoIt Français
Aller à : navigation, rechercher

Document original V3.3.6.1 :

###Function###
ObjGet

###Description###
Retrieves a reference to a COM object from an existing process or filename.

###Syntax###
ObjGet ( "filename" [, "classname"] )


###Parameters###
@@ParamTable@@
filename
	The full path and name to the file containing the object (See remarks).
classname
	[optional] The class of the object in the following format:
	"appname.objectype"
@@End@@

###ReturnValue###
@@ReturnTable@@
Success:	Returns an object.
Failure:	Returns 0 and sets @error to 1.
@@End@@


###Remarks###
The filename is optional if you want to use only the class name, but the parameter
can't be omitted. Use an empty string if you only want to use the classname. 
Like: $Object = ObjGet("","Excel.Application")

If you want to use a filename, the classname is optional. It's only required when 
multiple classes are defined to the same file type and you want to access a
specific class.

Keep in mind that not all computers have the same set of Objects. So <b>always</b> check for errors after calling ObjGet().

See the <a href="../intro/ComRef.htm">Obj/COM Reference</a> for more information about Objects.

###Related###
GUICtrlCreateObj, IsObj, ObjCreate, ObjEvent, ObjName


###Example###
@@IncludeExample@@


Document traduit V3.3.6.1 :

Texte en Français


Traducteur :

Contributeurs (pour les modifications avant le Wiki) :