Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@ public class ImageData
[LoadColumn(1)]
public string Label;
}
// <SnippetDeclareTypes>
// </SnippetDeclareTypes>
}
Original file line number Diff line number Diff line change
Expand Up @@ -104,40 +104,27 @@ private void button1_Click(object sender, System.EventArgs e)

}

//<snippet1>

//<snippet1>
private void validateUserEntry()
{

// Checks the value of the text.

if(serverName.Text.Length == 0)
{

// Initializes the variables to pass to the MessageBox.Show method.

string message = "You did not enter a server name. Cancel this operation?";
string caption = "Error Detected in Input";
string caption = "Error Detected in Input";
MessageBoxButtons buttons = MessageBoxButtons.YesNo;
DialogResult result;

// Displays the MessageBox.

result = MessageBox.Show(message, caption, buttons);

if (result == System.Windows.Forms.DialogResult.Yes)
{

// Closes the parent form.

this.Close();

}

}

}

//</snippet1>

//<snippet2>
Expand Down
Loading