- 易迪拓培训,专注于微波、射频、天线设计工程师的培养
HFSS15: Methods for IronPython
A collection of methods is made available to all python scripts to enable the use of existing scripts written in VBScript or Javascript. Additional utility methods to add messages to the desktop message window are also present.
AddErrorMessage(str), AddWarningMessage(str), AddInfoMessage(str) and AddFatalMessage(str) this family of methods allows a script to add messages to the product’s message window. All methods take a python string.
RunScriptFile(filename) runs the contents of the supplied file as a script. The type of the script (Javascript/VBScript) is deduced from the file extension.
SetScriptingLanguageToJavascript(), SetScriptingLanguageToVBScript() allows the script to change the syntax of the language being used in the Run*Command commands listed below. Once set, the language choice remains for the rest of the script execution or till it is changed. The default is VBScript.
RunScriptCommand(CommandString) runs the supplied script text. The language of the text is controlled by a previous call to SetScriptingLanguageToJavascript() or SetScriptingLanguageToVBScript()


