Пример #1
0
 private void bt_ok_Click(object sender, EventArgs e)
 {
     msgCenter.Objects.UserObject user = new msgCenter.Objects.UserObject();
     user.FirstName = tb_firstname.Text;
     user.MidName = tb_middlename.Text;
     user.LastName = tb_lastname.Text;
     user.Suffx = tb_suffix.Text;
     user.Birthday = tb_bmonth.Text + "/" + tb_bday.Text + "/" + tb_byear.Text;
     user.HomePhone = tb_phone1.Text + "-" + tb_phone2.Text + "-" + tb_phone3.Text;
     user.Gender = rb_male.Checked.ToString() ;
     user.Weight = float.Parse(tb_weight.Text);
     user.Height = float.Parse(tb_height_ft.Text) * 12 + float.Parse(tb_height_in.Text);
     user.Address_Street = tb_street.Text;
     user.Address_City = tb_city.Text;
     user.Address_State = tb_state.Text;
     user.Address_Zipcode = tb_zipcode.Text;
     user.EmgName = tb_emName.Text;
     user.EmgPhone = tb_emPhone1.Text + "-" + tb_emPhone2.Text + "-" + tb_emPhone3.Text;
     user.UseInsulin = cb_insulin.Checked;
     user.update();
     MessageBox.Show("Information Saved.");
     this.Visible = false;
 }
Пример #2
0
 private void bt_Emg_Click(object sender, EventArgs e)
 {
     if (tb_dialNumber.Text != string.Empty)
     {
         msgCenter.Objects.UserObject user = new msgCenter.Objects.UserObject();
         mainPro.CallPhone(user.getEmgPhoneNumber());
     }
 }