Differences

This shows you the differences between the selected revisions of the page.

2012-02-08 2012-02-08
registering anchor (martin) fixing link to WSF, small rewording (martin)
Line 21: Line 21:
As JScript and VBScript access COM classes via ''IDispatch'', they do not make use of type library, hence they do not have direct access to constants defined there, like ''[[library_sessionoptions#properties|Protocol.Sftp]]'' for instance. To use these, you have to instruct WSH to import the type library into the script namespace. As JScript and VBScript access COM classes via ''IDispatch'', they do not make use of type library, hence they do not have direct access to constants defined there, like ''[[library_sessionoptions#properties|Protocol.Sftp]]'' for instance. To use these, you have to instruct WSH to import the type library into the script namespace.
-You can use [[wp>Windows Script File]] (WSF) and its ''<reference>'' tag for that. It makes WSH convert all enums in the assembly interface into constants with name like ''<type>_<member>'', e.g. ''Protocol.Sftp'' becomes ''Protocol_Sftp''.+You can use [[wp>Windows_Script_File|Windows Script File]] (WSF) and its ''<reference>'' tag for that. It makes WSH import all //enums// from the assembly type library into constants in script namespace with name like ''<type>_<member>'', e.g. ''Protocol.Sftp'' becomes ''Protocol_Sftp''.
<code javascript> <code javascript>

Last modified: by martin