Пример #1
0
        private void buttonNew_Click(object sender, EventArgs e)
        {
            userForm form = new userForm(this.context);

            form.ShowDialog(this);
            loadList();
        }
Пример #2
0
 private void editSelection()
 {
     try
     {
         foreach (ListViewItem item in listView.SelectedItems)
         {
             int  id = Convert.ToInt16(item.Tag);
             User user;
             if (id.Equals(context.User.Id))
             {
                 user = context.User;
             }
             else
             {
                 user = new User(id);
             }
             userForm form = new userForm(this.context, user);
             form.ShowDialog(this);
             loadList();
         }
     }
     catch (Exception ex)
     {
         Tools.ShowError("Unable to load user\n" + ex.Message);
     }
 }
Пример #3
0
        private void profiletoolStripMenuItem_Click(object sender, EventArgs e)
        {
            userForm form = new userForm(context, context.User);

            form.ShowDialog(this);
        }
Пример #4
0
 private void editSelection()
 {
     try
     {
         foreach (ListViewItem item in listView.SelectedItems)
         {
             int id = Convert.ToInt16(item.Tag);
             User user;
             if (id.Equals(context.User.Id))
             {
                 user = context.User;
             }
             else
             {
                 user = new User(id);
             }
             userForm form = new userForm(this.context, user);
             form.ShowDialog(this);
             loadList();
         }
     }
     catch (Exception ex)
     {
         Tools.ShowError("Unable to load user\n" + ex.Message);
     }
 }
Пример #5
0
 private void buttonNew_Click(object sender, EventArgs e)
 {
     userForm form = new userForm(this.context);
     form.ShowDialog(this);
     loadList();
 }
Пример #6
0
 private void profiletoolStripMenuItem_Click(object sender, EventArgs e)
 {
     userForm form = new userForm(context, context.User);
     form.ShowDialog(this);
 }