示例#1
0
 public void btnAdd_Click(object sender, EventArgs e)
 {
     if (Properties.Settings.Default.playSounds)
         Sound.Click.Play();
     Form additem = new BudgetItemForm(-1);
     additem.ShowDialog();
 }
示例#2
0
 private void viewAssetList_MouseDoubleClick(object sender, MouseEventArgs e)
 {
     if (this.assetListView.SelectedIndices[0] != -1)
     {
         if (Properties.Settings.Default.playSounds)
             Sound.Click.Play();
         int key = Convert.ToInt32(assetListView.SelectedItems[0].SubItems[3].Text);
         BudgetItem toEdit = budgetItemDictionary[key];
         Form edit = new BudgetItemForm(ClsStorage.currentClub.budget.IndexOf(toEdit));
         edit.ShowDialog();
         edit.Dispose();
     }
 }
示例#3
0
 private void lvMain_MouseDoubleClick(object sender, MouseEventArgs e)
 {
     // something is selected
     if (lvMain.SelectedIndices[0] != -1)
     {
         if (Properties.Settings.Default.playSounds)
             Sound.Click.Play();
         // open edit budget item dialog box
         int key = Convert.ToInt32(lvMain.SelectedItems[0].SubItems[7].Text);
         BudgetItem toEdit = budgetItemDictionary[key];
         Form edit = new BudgetItemForm(ClsStorage.currentClub.budget.IndexOf(toEdit));
         edit.ShowDialog();
         edit.Dispose();
     }
 }