/// <summary> /// Load the User Info based on the current Volunteer /// </summary> protected void LoadUserInfo() { sp_Volunteer_Cache VolCASH = new sp_Volunteer_Cache(); sp_Volunteer_DM VolDM = new sp_Volunteer_DM(); VolDM = VolCASH.ListVolunteers(UserID); rTBFirstName.Text = cCommonFunctions.HandleDBNull(VolDM.VolFirstName); rTBMiddleName.Text = cCommonFunctions.HandleDBNull(VolDM.VolMiddleName); rTBLastName.Text = cCommonFunctions.HandleDBNull(VolDM.VolLastName); }
/// <summary> /// SaveUserInfo - Called from parent screen, build a domain model and save the user info /// </summary> internal void SaveUserInfo() { sp_Volunteer_Cache VolCASH = new sp_Volunteer_Cache(); sp_Volunteer_DM VolDM = new sp_Volunteer_DM(); // Get the VolID from the parent form VolDM.VolID = new Guid(((HiddenField)Parent.FindControl("hdVolID")).Value); // Get the other info from the controls in this container VolDM.VolFirstName = cCommonFunctions.SetNullIfEmpty(rTBFirstName.Text.ToString()); VolDM.VolMiddleName = cCommonFunctions.SetNullIfEmpty(rTBMiddleName.Text.ToString()); VolDM.VolLastName = cCommonFunctions.SetNullIfEmpty(rTBLastName.Text.ToString()); VolCASH.UpdateVolunteerContext(VolDM); }
protected void LoadPage() { MembershipUser currentUser = Membership.GetUser(); Guid? UserID = (Guid)currentUser.ProviderUserKey; sp_Volunteer_Cache VolCASH = new sp_Volunteer_Cache(); sp_Volunteer_DM VolDM = new sp_Volunteer_DM(); VolDM = VolCASH.ListVolunteers(UserID); hdVolID.Value = DataBinder.Eval(VolDM, "VolID").ToString(); hdEditView.Value = "1"; //Handle ucVolBasicInfo parameters ucVolBasicInfo.UserID = UserID; }
protected void LoadPage() { MembershipUser currentUser; currentUser = Membership.GetUser(); Guid? UserID; UserID = (Guid)currentUser.ProviderUserKey; System.Web.Caching.Cache cache = HttpRuntime.Cache; sp_Volunteer_Cache VolCASH = new sp_Volunteer_Cache(); sp_Volunteer_DM VolDM = new sp_Volunteer_DM(); VolDM = VolCASH.ListVolunteers(UserID); ctl02.Text = (string)DataBinder.Eval(VolDM, "VolID"); //Cache.Add(UserID.ToString(), VolDM, null, DateTime.Now.AddSeconds(60), Cache.NoSlidingExpiration, CacheItemPriority.High, null); }