コード例 #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="PersonalAccountControl"/> class.
 /// </summary>
 /// <param name="a">main controler</param>
 /// <param name="curr">this user</param>
 public PersonalAccountControl(MainController a, User curr)
 {
     InitializeComponent();
     firstNameTxt.Text = curr.FirstName;
     lastNameTxt.Text = curr.LastName;
     addressTxt.Text = curr.Adress;
     countryTxt.Text = curr.Country;
     postCodeTxt.Text = curr.ZipCode;
     genderTxt.Text = curr.Gender;
     emailTxt.Text = curr.Email;
     telTxt.Text = curr.Phone;
     usernameTxt.Text = curr.UserName;
     main = a;
 }
コード例 #2
0
ファイル: User.cs プロジェクト: Yapko/NewShop
 public User Clone()
 {
     User res = new User();
     res.UserName = (string)UserName.Clone();
     res.FirstName = (string)FirstName.Clone();
     res.LastName = (string)LastName.Clone();
     res.Email = (string)Email.Clone();
     res.Password = (string)Password.Clone();
     res.Phone = (string)Phone.Clone();
     res.Adress = (string)Adress.Clone();
     res.Country = (string)Country.Clone();
     res.ZipCode = (string)ZipCode.Clone();
     res.Gender = (string)Gender.Clone();
     res.Status = (string)Status.Clone();
     res.ID = ID;
     return res;
 }
コード例 #3
0
ファイル: MainWnd.cs プロジェクト: Yapko/NewShop
        /// <summary>
        /// Create account in main form
        /// </summary>
        /// <param name="position">position of upper left ungle</param>
        /// <param name="curr">this user</param>
        public void LoadAccount(Point position, User curr)
        {
            //create login
            PersonalAccountControl account = new PersonalAccountControl(control, curr);
            // set location in center of form
            account.Location = position;

            // add login to mainform controls
            this.Controls.Add(account);
        }