CloneUnit() public method

public CloneUnit ( string unitId, string data ) : string
unitId string
data string
return string
Example #1
0
 private void cloneUnitToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if (tabControl1.SelectedTab != null)
     {
         string id   = tabControl1.SelectedTab.Text;
         string data = (tabControl1.SelectedTab.Controls[0]).Text;
         try {
             string res = mod.CloneUnit(id, data);
             AddTab(res);
         } catch (Exception ex) {
             MessageBox.Show("Error while cloning " + id + "\r\n" + ex.Message, "Cloning errror", MessageBoxButtons.OK, MessageBoxIcon.Warning);
         }
     }
 }