Esempio n. 1
0
        private bool Edit(Bitmap icon)
        {
            try
            { 
                using (var frm = new Forms.BTSS.FormProject())
                {
                    frm.Operation = Global.Operation.UPDATE;
                    frm.Icon = Icon.FromHandle(icon.GetHicon());
                    frm.Text = "Project[EDIT]";
                    frm.ProjectId = id;
                    if (frm.ShowDialog() == DialogResult.OK)
                        RefreshListing();
                }

                return true;
            }
            catch (Exception)
            {
                throw;
            } 
        }
Esempio n. 2
0
 private bool View(Bitmap icon)
 {
     try
     {
         using (var frm = new Forms.BTSS.FormProject())
         {
             frm.Operation = Global.Operation.VIEW;
             frm.Icon = Icon.FromHandle(icon.GetHicon());
             frm.Text = "Project[VIEW]";
             frm.ProjectId = id;
             frm.ShowDialog();
         }
         return true ;
     }
     catch (Exception)
     {
         throw;
     }
 }
Esempio n. 3
0
 private bool New(Bitmap icon)
 {
     try
     {  
         using (var frm = new Forms.BTSS.FormProject())
         {
             frm.Operation = Global.Operation.INSERT;
             frm.Icon = Icon.FromHandle(icon.GetHicon());
             frm.Text = "Project[NEW]";
             frm.OnSave += new EventHandler(RefreshOnSave);
             if (frm.ShowDialog() == DialogResult.OK)
                 RefreshListing();
         }
         return true;
     }
     catch (Exception)
     {
         throw;
     } 
 }