示例#1
0
 void ButtonAddClick(object sender, EventArgs e)
 {
     using (SalesInfoDetailForm f = new SalesInfoDetailForm()) {
         if (WorkbenchSingleton.AddDialog(f) == DialogResult.OK)
         {
             info.AddDetail(f.Detail);
             RefreshList();
         }
     }
 }
示例#2
0
 void ListView1DoubleClick(object sender, EventArgs e)
 {
     if (listView1.SelectedItems.Count > 0)
     {
         SalesInfoDetail i = info.Details[listView1.SelectedItems[0].Index];
         using (SalesInfoDetailForm f = new SalesInfoDetailForm(i)) {
             if (WorkbenchSingleton.AddDialog(f) == DialogResult.OK)
             {
                 RefreshList();
             }
         }
     }
 }