Adding error message for single field set attempt.
authorsl
Tue, 16 Dec 2014 20:02:06 +0100
changeset 819bcab0dfa376
parent 80 408ef0501cb7
child 83 150c4a9d7e26
Adding error message for single field set attempt.
Client/MainForm.cs
     1.1 --- a/Client/MainForm.cs	Tue Dec 16 18:05:55 2014 +0100
     1.2 +++ b/Client/MainForm.cs	Tue Dec 16 20:02:06 2014 +0100
     1.3 @@ -134,7 +134,14 @@
     1.4              //TextField top = new TextField(0, textBoxTop.Text, ContentAlignment.MiddleLeft);
     1.5              iTextFieldTop.Text = textBoxTop.Text;
     1.6              iTextFieldTop.Alignment = Alignment;
     1.7 -            iClient.SetField(iTextFieldTop);
     1.8 +            bool res = iClient.SetField(iTextFieldTop);
     1.9 +
    1.10 +            if (!res)
    1.11 +            {
    1.12 +                MessageBox.Show("Create you fields first", "Field update error", MessageBoxButtons.OK, MessageBoxIcon.Error);
    1.13 +            }
    1.14 +
    1.15 +
    1.16          }
    1.17  
    1.18          private void buttonSetText_Click(object sender, EventArgs e)