Пример #1
0
 protected override string GetArgument(int index, RCProcess.CustomCommandParser.CommandArg arg)
 {
     if (arg.Type == RCProcess.CustomCommandParser.DataType.ServerGroup)
     {
         return(this.currentServer);
     }
     return(base.GetArgument(index, arg));
 }
Пример #2
0
        protected virtual string GetArgument(int index, RCProcess.CustomCommandParser.CommandArg arg)
        {
            switch (arg.Type)
            {
            case RCProcess.CustomCommandParser.DataType.Date:
            {
                DateTimePicker dateTimePicker = this.controlArgs[index] as DateTimePicker;
                return(dateTimePicker.Value.ToString("yyyy/MM/dd HH:mm:ss"));
            }

            case RCProcess.CustomCommandParser.DataType.Boolean:
            {
                TwoRadioButton twoRadioButton = this.controlArgs[index] as TwoRadioButton;
                if (!twoRadioButton.Checked)
                {
                    return("0");
                }
                return("1");
            }

            default:
                return(this.controlArgs[index].Text);
            }
        }
Пример #3
0
 public ArgumentControl(Label label, Control control, RCProcess.CustomCommandParser.CommandArg argument)
 {
     this.Label    = label;
     this.Control  = control;
     this.Argument = argument;
 }