バッチ/インタラクティブモードを取得するネイティブにモーダルウィンドウを非表示にする方法があるかどうか疑問に思っています。 バッチインタラクティブはそうではないようです。
Names default to here(1);
batch interactive(1);
new window("Test", <<MODAL></MODAL>
だから、私は現在のバッチインタラクティブモードを取得して、このようなことをする方法があるかどうか疑問に思っています。
Names default to here(1);
batch interactive(1);
if(batch interactive(), // or some other internal variable
print("YAY")
, // else
new window("Test", <<MODAL></MODAL>
明らかに、独自のバッチ変数を作成できますが、何か組み込まれているのではないかと思っています。
Re: バッチ/インタラクティブ モードを取得する情報をありがとう。
JMP サポートの助けを借りて:)
batch interactive(boolean) returns the previous setting.
Names default to here(1);
//works for both options
//batch interactive(0);
//batch interactive(1);
last setting = batch interactive(1); // return value is last setting
batch interactive(last setting); // reset it in case we set it erroneously
if(last setting,
print("YAY")
, // else
new window("Test", <<MODAL> </MODAL>
Re: バッチ/インタラクティブ モードを取得する私の場合は常に 1 から始まるので、JMP はバッチ処理されていると思います。しかし、それは絶対に違います。起動すると、最初の戻り値は 0 になりますか?
Re: バッチ/インタラクティブ モードを取得するいい視点ね ...
スクリプトを実行すると、JMPはデフォルトで「バッチインタラクティブ」が1に設定された状態で自動的に起動するようです。
- 警告メッセージが表示されず、スクリプトの動作に支障をきたさないようにします。
それは絶対に違います。
おそらく「警告」にはさまざまな種類があるのでしょうか? - そのうちのいくつかは、このデフォルトの「バッチ インタラクティブ」 ~ 1 設定を無視するため、「黙らせる」には JSL 経由で明示的にバッチ インタラクティブ (1)を送信する必要がありますか?
Eval(arg)とEval(Eval Expr( .... Expr(arg) ...) の比較:
JMP プラットフォームと関数の一部では、変数参照の問題を修正するために引数を Eval()するだけで済みます。
残りの部分では、 Eval(arg)アプローチは失敗し、ユーザーはEval(Eval Expr( .... Expr(arg) ... ) にフォールバックする必要があります。
...そして、どの関数がどのグループに属するかを調べるのは、JSL スクリプト作成者と JMP サポートの毎日の楽しみです。
Re: バッチ/インタラクティブ モードを取得するバッチインタラクティブのさまざまな動作とさまざまな「デフォルト」モードの例:
Names Default To Here( 1 );
testMarkup = Function( {},
text = Text Box("Bad XML <");
text << markup;
);
// Run the next four lines individually
testMarkup(); // no special setting: default
batch interactive(1);testMarkup(); // batch interactive is turned "on" so we see an error
batch interactive(0);testMarkup(); // batch interactive is turned off so we can show an error
new window("test",buttonbox("Test", testMarkup())); // running jsl in response to a click is not batch interactive mode
new window("test",buttonbox("Test", batch interactive(1);testMarkup())); // set batch interactive to 1 so the error message goes to the log and there is no modal dialog
// the findings:
// default -> no dialog
// 1 -> no dialog
// 0 -> dialog
// Run the next 3 lines individually to check if formula errors behave the same as above
:col1 << remove formula(); // no special setting: default
batch interactive(1);:col1 << remove formula(); // batch interactive is turned "on"" so we see an error
batch interactive(0);:col1 << remove formula(); // batch interactive is turned off so we can show an error
// the findings:
// default -> dialog (!!!!!)
// 1 -> no dialog
// 0 -> dialogJMP サポートから次の情報を入手しました:
Batch Interactive()関数は文書化されていません。動作は状況によって異なる可能性があり、将来変更される可能性があります。実質的には、実験的であり、サポートされていないと考えられます。