WSH - List Available Functions
I would be interested to know if there is any way for a script to obtain a list of available methods/functions wi开发者_JS百科thin a Windows Script Host (VBScript) being hosted by some parent application?
If it was a .NET app, it would be using reflection, but I'm not sure if there is anything similar for WSH.
Windows Script Host is an environment. It cannot be "hosted by some parent application". Are you asking about using an alternative scripting engine? You mention VBScript which requires one of the built in scripting engines, neither of which provide any methods of reflection.
http://www.w3schools.com/vbscript/vbscript_ref_functions.asp
Parsing .vbs file.
Or write vbscript Class and use IDL, DCOM analogy.
.Net? Use Powershell.
精彩评论