実行可能ファイルまたはdllを実行します。 execute がコールするファイルまたは dll が見つからない場合、この関数は False を返します。
最初のパラメータは、実行する項目のパスです。 dll のパスの場合は、2 つのコロンのすぐ後に API 関数を指定する必要があります。 dll コールの形式は、PATH::APIFunctionName です。 dll に対するExecuteでは、以下の 2 種類の関数のみコールできます。
int FunctionName();
int FunctionName( const char * );
コールがコマンド ライン引数を取る場合は、引数を入力するか、空の文字列を入力します。
スクリプトが、実行可能ファイルが完了するまで待機するかどうかを示すブール値です。 dll コールの場合、このパラメータは無視されます。
/*executes notepad with the following file, myfile.txt and waits for the process to end.*/ Execute( "c:\\windows\\notepad.exe", "myfile.txt", true ); /*executes notepad without parameters and waiting.*/ Execute( "c:\\windows\\notepad.exe" ); /* makes a call into the dll with parameters*/ Execute( "c\\windows\\Somelib.dll::CheckNetwork", "000d1");
** dll の PATH::APIFunctionName の形式に注意してください。
|
Copyright © 2014 CA Technologies.
All rights reserved.
|
|