/// <summary> /// Execute a script validation for a passed document in a code panel. /// This method has to be here in VisionScriptPanel because we need access to ScriptManager. /// </summary> public override void ValidateScriptDocumentAutomatic(SourceCodeEditorPanelScript doc) { if (doc != null) { // Call to the actual script validation String errorResult = string.Empty; bool hasError = !ScriptManager.ValidateScriptNoRun(doc.ScriptText, out errorResult); // Forward error information to the document -> updates UI and error status for this doc doc.HandleAutomaticScriptValidation(hasError, errorResult); // Update doc panel and status bar since both might have to react with changed icons / text dockPanel_All.Refresh(); UpdateStatusBar(); } }