Table of Contents
CanEvalScript Property

Returns a value indicating whether EvalScript can be called at this moment.

Syntax
 public Boolean CanEvalScript { get; }
Remarks

EvalScript can not be called when:

  • Before JavaScript context has been initialized. There is a short period after the WebView has been created when it has not yet initialized the JavaScript context for the window object thus is not ready to run JavaScript code yet;
  • Before another JavaScript call returns. JavaScript code can not be re-entered, as such you can not call EvalScript again before the previous EvalScript returns;

To safely execute JavaScript code, use QueueScriptTask.

See Also