entity.MapForms.MapForm.AskForTagName C# (CSharp) Method

AskForTagName() private method

The ask for tag name.
private AskForTagName ( ) : void
return void
        private void AskForTagName()
        {
            Form newForm = new Form();
            newForm.Text = "Select new tag name";
            newForm.Size = new Size(500, 110);
            newForm.FormBorderStyle = FormBorderStyle.FixedDialog;
            newForm.FormClosing += this.newForm_FormClosing;

            #region label data

            Label newLabel = new Label();
            newLabel.Text = "New Name";
            newLabel.Location = new Point(10, 14);
            newLabel.Size = new Size(68, 18);

            #endregion

            #region Textbox Data

            TextBox newTextBox = new TextBox();
            newTextBox.Location = new Point(80, 10);
            newTextBox.Size = new Size(400, 10);
            newTextBox.Text = newName; // Set the name to our predicted name

            #endregion

            #region Button Data

            Button newAddButton = new Button();
            newAddButton.Text = "Create new tag";
            newAddButton.AutoSize = false;
            newAddButton.Size = new Size(160, 30);
            newAddButton.Location = new Point(170, 40);
            newAddButton.Parent = newForm;
            newAddButton.Click += this.newAddButton_Click;

            #endregion

            #region Add Controls

            newForm.Controls.Add(newLabel);
            newForm.Controls.Add(newTextBox);
            newForm.Controls.Add(newAddButton);
            newForm.ShowDialog();

            #endregion
        }
MapForm