public override List <Control> Render(IfrmCommandEditor editor, ICommandControls commandControls) { base.Render(editor, commandControls); RenderedControls.AddRange(commandControls.CreateDefaultInputGroupFor("v_RetryCount", this, editor)); RenderedControls.AddRange(commandControls.CreateDefaultInputGroupFor("v_RetryInterval", this, editor)); RenderedControls.AddRange(commandControls.CreateDefaultDropdownGroupFor("v_Option", this, editor)); ((ComboBox)RenderedControls[7]).SelectedIndexChanged += optionComboBox_SelectedIndexChanged; //CSharp Controls _cSharpControls = new List <Control>(); _cSharpControls.AddRange(commandControls.CreateDefaultInputGroupFor("v_Condition", this, editor)); RenderedControls.AddRange(_cSharpControls); //no CSharp Controls _noCSharpControls = new List <Control>(); _noCSharpControls.AddRange(commandControls.CreateDefaultDropdownGroupFor("v_LogicType", this, editor)); //create controls var controls = commandControls.CreateDefaultDataGridViewGroupFor("v_IfConditionsTable", this, editor); _ifConditionHelper = controls[2] as DataGridView; //handle helper click var helper = controls[1] as CommandItemControl; helper.Click += (sender, e) => CreateIfCondition(sender, e, editor, commandControls); //add for rendering _noCSharpControls.AddRange(controls); //define if condition helper _ifConditionHelper.Width = 450; _ifConditionHelper.Height = 200; _ifConditionHelper.AutoGenerateColumns = false; _ifConditionHelper.AutoSizeColumnsMode = DataGridViewAutoSizeColumnsMode.None; _ifConditionHelper.Columns.Add(new DataGridViewTextBoxColumn() { HeaderText = "Condition", DataPropertyName = "Statement", ReadOnly = true, AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill }); _ifConditionHelper.Columns.Add(new DataGridViewTextBoxColumn() { HeaderText = "CommandData", DataPropertyName = "CommandData", ReadOnly = true, Visible = false }); _ifConditionHelper.Columns.Add(new DataGridViewButtonColumn() { HeaderText = "Edit", UseColumnTextForButtonValue = true, Text = "Edit", Width = 45 }); _ifConditionHelper.Columns.Add(new DataGridViewButtonColumn() { HeaderText = "Delete", UseColumnTextForButtonValue = true, Text = "Delete", Width = 60 }); _ifConditionHelper.AllowUserToAddRows = false; _ifConditionHelper.AllowUserToDeleteRows = true; _ifConditionHelper.CellContentClick += (sender, e) => IfConditionHelper_CellContentClick(sender, e, editor, commandControls); RenderedControls.AddRange(_noCSharpControls); return(RenderedControls); }
public override List <Control> Render(IfrmCommandEditor editor, ICommandControls commandControls) { base.Render(editor, commandControls); RenderedControls.AddRange(commandControls.CreateDefaultDataGridViewGroupFor("v_ColumnNameDataTable", this, editor)); RenderedControls.AddRange(commandControls.CreateDefaultOutputGroupFor("v_OutputUserVariableName", this, editor)); return(RenderedControls); }
public override List <Control> Render(IfrmCommandEditor editor, ICommandControls commandControls) { base.Render(editor, commandControls); RenderedControls.AddRange(commandControls.CreateDefaultInputGroupFor("v_JsonObject", this, editor)); RenderedControls.AddRange(commandControls.CreateDefaultDataGridViewGroupFor("v_ParseObjects", this, editor)); return(RenderedControls); }
public override List <Control> Render(IfrmCommandEditor editor, ICommandControls commandControls) { base.Render(editor, commandControls); RenderedControls.AddRange(commandControls.CreateDefaultInputGroupFor("v_InstanceName", this, editor)); RenderedControls.AddRange(commandControls.CreateDefaultDataGridViewGroupFor("v_WebSearchParameter", this, editor)); _elementActionDropdown = commandControls.CreateDropdownFor("v_WebAction", this); RenderedControls.Add(commandControls.CreateDefaultLabelFor("v_WebAction", this)); RenderedControls.AddRange(commandControls.CreateUIHelpersFor("v_WebAction", this, new Control[] { _elementActionDropdown }, editor)); _elementActionDropdown.SelectionChangeCommitted += ElementActionDropdown_SelectionChangeCommitted; RenderedControls.Add(_elementActionDropdown); _elementParameterControls = commandControls.CreateDefaultDataGridViewGroupFor("v_WebActionParameterTable", this, editor); ((DataGridView)_elementParameterControls[2]).AllowUserToAddRows = false; RenderedControls.AddRange(_elementParameterControls); return(RenderedControls); }
public override List <Control> Render(IfrmCommandEditor editor, ICommandControls commandControls) { base.Render(editor, commandControls); RenderedControls.AddRange(commandControls.CreateDefaultInputGroupFor("v_FilePath", this, editor)); RenderedControls.AddRange(commandControls.CreateDefaultInputGroupFor("v_ClassName", this, editor)); RenderedControls.AddRange(commandControls.CreateDefaultInputGroupFor("v_MethodName", this, editor)); RenderedControls.AddRange(commandControls.CreateDefaultDataGridViewGroupFor("v_MethodParameters", this, editor)); RenderedControls.AddRange(commandControls.CreateDefaultOutputGroupFor("v_OutputUserVariableName", this, editor)); return(RenderedControls); }
public override List <Control> Render(IfrmCommandEditor editor, ICommandControls commandControls) { base.Render(editor, commandControls); RenderedControls.AddRange(commandControls.CreateDefaultInputGroupFor("v_DataTable", this, editor)); RenderedControls.AddRange(commandControls.CreateDefaultDropdownGroupFor("v_FilterOption", this, editor)); ((ComboBox)RenderedControls[4]).SelectedIndexChanged += OptionComboBox_SelectedIndexChanged; _rowFilterControls = commandControls.CreateDefaultInputGroupFor("v_RowFilter", this, editor); RenderedControls.AddRange(_rowFilterControls); _dataControls = commandControls.CreateDefaultDataGridViewGroupFor("v_DataRowDataTable", this, editor); RenderedControls.AddRange(_dataControls); RenderedControls.AddRange(commandControls.CreateDefaultOutputGroupFor("v_OutputUserVariableName", this, editor)); return(RenderedControls); }
public override List <Control> Render(IfrmCommandEditor editor, ICommandControls commandControls) { base.Render(editor, commandControls); RenderedControls.AddRange(commandControls.CreateDefaultInputGroupFor("v_DataTable", this, editor)); RenderedControls.AddRange(commandControls.CreateDefaultDataGridViewGroupFor("v_DataRowDataTable", this, editor)); CommandItemControl loadSchemaControl = new CommandItemControl(); loadSchemaControl.ForeColor = Color.White; loadSchemaControl.Font = new Font("Segoe UI Semilight", 10); loadSchemaControl.CommandDisplay = "Load Column Names From Existing DataTable"; loadSchemaControl.CommandImage = Resources.command_spreadsheet; loadSchemaControl.Click += LoadSchemaControl_Click; RenderedControls.Add(loadSchemaControl); _dataTableCreationCommands = editor.ConfiguredCommands.Where(f => f is CreateDataTableCommand) .Select(f => (CreateDataTableCommand)f) .ToList(); return(RenderedControls); }
public override List <Control> Render(IfrmCommandEditor editor, ICommandControls commandControls) { base.Render(editor, commandControls); RenderedControls.AddRange(commandControls.CreateDefaultInputGroupFor("v_ScriptPath", this, editor)); RenderedControls.AddRange(commandControls.CreateDefaultDropdownGroupFor("v_ArgumentType", this, editor)); ((ComboBox)RenderedControls[5]).SelectedIndexChanged += ArgumentTypeComboBox_SelectedIndexChanged; _commandLineInputControls = commandControls.CreateDefaultInputGroupFor("v_ScriptArgs", this, editor); RenderedControls.AddRange(_commandLineInputControls); _variableInputControls = commandControls.CreateDefaultDataGridViewGroupFor("v_VariableArgumentsDataTable", this, editor); RenderedControls.AddRange(_variableInputControls); RenderedControls.AddRange(commandControls.CreateDefaultDropdownGroupFor("v_HasOutput", this, editor)); ((ComboBox)RenderedControls[13]).SelectedIndexChanged += HasOutputComboBox_SelectedIndexChanged; _outputControls = commandControls.CreateDefaultOutputGroupFor("v_OutputUserVariableName", this, editor); RenderedControls.AddRange(_outputControls); return(RenderedControls); }