Esempio n. 1
0
        private bool AddUser()
        {
            bool blnResult = false;

            User newUser = new User(ref m_DL);

            newUser.FName = txtFname.Text.Trim();
            newUser.LName = txtLname.Text.Trim();
            newUser.Address = txtAddress.Text.Trim();
            newUser.Uemail = txtUemail.Text.Trim();

            //Write record to DB
            blnResult = newUser.Update();

            return blnResult;
        }
Esempio n. 2
0
        private bool FindUser(string strUemail, out User objUser)
        {
            User objU;
            string email;

            email = strUemail.Trim();

            objU = new User(ref m_DL);
            objU.Populate(email);

            if (!objU.IsNew)
            {
                objUser = objU;
                return true;
            }

            objUser = null;
            return false;
        }
Esempio n. 3
0
        private bool UpdateUser(ref User objUser)
        {
            bool blnResult = false;

            objUser.FName = txtFname.Text.Trim();
            objUser.LName = txtLname.Text.Trim();
            objUser.Address = txtAddress.Text.Trim();
            objUser.Uemail = txtUemail.Text.Trim();

            //Write record to DB
            blnResult = objUser.Update();

            return blnResult;
        }