public void VerifyScript() { ClearCommandGrid(); script.Clear(); script.ChangeState(cmbInitState.SelectedItem.GetType().Name); foreach (Command command in ListItems) { script.Enqueue(command); } try { script.Invoke(false, false); } catch (NotSupportedCommandException ex) { log.Error(ex.Message); listBox1.SelectedItem = ex.Command; listBox1.Focus(); } }