SECI  1
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Properties Events
NameTab.cs
Go to the documentation of this file.
1 using System;
2 using System.Collections.Generic;
3 using System.ComponentModel;
4 using System.Data;
5 using System.Drawing;
6 using System.Linq;
7 using System.Text;
8 using System.Windows.Forms;
9 
10 namespace SeciUserInterface.Dialogs.Tabs
11 {
12  public partial class NameTab : Form
13  {
14  public string TabName;
15 
16  public NameTab()
17  {
18  InitializeComponent();
19  }
20 
21  private void NameTab_Load(object sender, EventArgs e)
22  {
23  if (!String.IsNullOrEmpty(TabName))
24  {
25  txtName.Text = TabName;
26  }
27  }
28 
29  private void btnOK_Click(object sender, EventArgs e)
30  {
31  if (String.IsNullOrEmpty(txtName.Text.Trim()))
32  {
33  MessageBox.Show("Please enter a name for the tab.");
34  return;
35  }
36 
37  TabName = txtName.Text.Trim();
38  DialogResult = DialogResult.OK;
39  Close();
40  }
41 
42 
43  }
44 }
void btnOK_Click(object sender, EventArgs e)
Definition: NameTab.cs:29
void NameTab_Load(object sender, EventArgs e)
Definition: NameTab.cs:21