private string InputObject(RowCollectionRow row, Tag2 tag)
        {
            string result = null;

            InputBox inputBox;
            try
            {
                if (tag.Child.Name == "repeat")
                {
                    //
                    // NOTE this need to be like $input.once object
                    //
                    //{=input.repeat.[Value]}
                    inputBox = new InputBox("Write text", tag.Child.Name, "Replace tag with text...");
                    inputBox.ShowDialog(System.Windows.Forms.Application.OpenForms[0]);
                    result = inputBox.InputTekst;
                }
                else if (tag.Child.Name == "once")
                {
                    result = inputObject.ProcessTag(tag);
                    if (result == null)
                    {
                        result = constError_SyntaxError;
                    }
                }
                else
                {
                    ModuleLog.Write(new string[] { constError_CommandNotFound, tag.InputText }, this, "InputObject", ModuleLog.LogType.ERROR);
                    result = constError_SyntaxError;
                }
            }
            catch (Exception ex)
            {
                ModuleLog.Write(new string[] { constError_ExecutingBlock, tag.InputText }, this, "InputObject", ModuleLog.LogType.DEBUG);
                ModuleLog.Write(ex, this, "InputObject", ModuleLog.LogType.ERROR);
                result = constError_SyntaxError;
            }
            return result;
        }
 private InputBox InputObject(Array objectValue)
 {
     //{=input.once.Text}
     InputBox inputBox;
     try
     {
         inputBox = new InputBox("Write all texts", objectValue, "");
         inputBox.ShowDialog(System.Windows.Forms.Application.OpenForms[0]);
     }
     catch (Exception ex)
     {
         ModuleLog.Write(ex, this, "InputObject", ModuleLog.LogType.ERROR);
         inputBox = null;
     }
     return inputBox;
 }
Example #3
0
        private void CallUserInput()
        {
            InputBox inputBox;
            NameValueDataStruct nameValueStruct;
            try
            {
                inputBox = new InputBox("Input requested values", list, "");
                inputBox.ShowDialog(System.Windows.Forms.Application.OpenForms[0]);

                for (int i = 0; i < list.Count; i++)
                {
                    nameValueStruct = (NameValueDataStruct)list[i];
                    nameValueStruct.Value = inputBox[i];
                    list[i] = nameValueStruct;
                }

            }
            catch (Exception ex)
            {
                ModuleLog.Write(ex, this, "InputObject", ModuleLog.LogType.ERROR);
                inputBox = null;
            }
        }