Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Update email adress membershipuser

Reply
Thread Tools

Update email adress membershipuser

 
 
=?Utf-8?B?TGlubg==?=
Guest
Posts: n/a
 
      06-06-2006
Hi,
I am trying to update the e-mail for å user (as an admin), but the new
e-mail address is not saved.
The msgbox gives met he correct email, but when I reload my data in the
gridview, the old value is displayed.

Anyone any idea?

Dim user As MembershipUser
Dim bruker as string
bruker = CType(sender, GridView).DataKeys(e.RowIndex).Value
user = Membership.GetUser(bruker)

user.Email = CType(CType(sender,
GridView).Rows(e.RowIndex).Cells(4).Controls(0), TextBox).Text
MsgBox(user.Email)
MsgBox(bruker)

 
Reply With Quote
 
 
 
 
Ray Booysen
Guest
Posts: n/a
 
      06-06-2006
Don't you need to call an update method to save it?

Linn wrote:
> Hi,
> I am trying to update the e-mail for å user (as an admin), but the new
> e-mail address is not saved.
> The msgbox gives met he correct email, but when I reload my data in the
> gridview, the old value is displayed.
>
> Anyone any idea?
>
> Dim user As MembershipUser
> Dim bruker as string
> bruker = CType(sender, GridView).DataKeys(e.RowIndex).Value
> user = Membership.GetUser(bruker)
>
> user.Email = CType(CType(sender,
> GridView).Rows(e.RowIndex).Cells(4).Controls(0), TextBox).Text
> MsgBox(user.Email)
> MsgBox(bruker)
>

 
Reply With Quote
 
 
 
 
=?Utf-8?B?TGlubg==?=
Guest
Posts: n/a
 
      06-06-2006
There is no update method on MembershipUser (nor save as on ProfileCommon)


"Ray Booysen" wrote:

> Don't you need to call an update method to save it?
>
> Linn wrote:
> > Hi,
> > I am trying to update the e-mail for å user (as an admin), but the new
> > e-mail address is not saved.
> > The msgbox gives met he correct email, but when I reload my data in the
> > gridview, the old value is displayed.
> >
> > Anyone any idea?
> >
> > Dim user As MembershipUser
> > Dim bruker as string
> > bruker = CType(sender, GridView).DataKeys(e.RowIndex).Value
> > user = Membership.GetUser(bruker)
> >
> > user.Email = CType(CType(sender,
> > GridView).Rows(e.RowIndex).Cells(4).Controls(0), TextBox).Text
> > MsgBox(user.Email)
> > MsgBox(bruker)
> >

>

 
Reply With Quote
 
=?Utf-8?B?TGlubg==?=
Guest
Posts: n/a
 
      06-07-2006
Figured out...
Membership.UpdateUser(bruker)
Could be what you ment, Roy, I just did not get it
Thanks anyway.



"Linn" wrote:

> There is no update method on MembershipUser (nor save as on ProfileCommon)
>
>
> "Ray Booysen" wrote:
>
> > Don't you need to call an update method to save it?
> >
> > Linn wrote:
> > > Hi,
> > > I am trying to update the e-mail for å user (as an admin), but the new
> > > e-mail address is not saved.
> > > The msgbox gives met he correct email, but when I reload my data in the
> > > gridview, the old value is displayed.
> > >
> > > Anyone any idea?
> > >
> > > Dim user As MembershipUser
> > > Dim bruker as string
> > > bruker = CType(sender, GridView).DataKeys(e.RowIndex).Value
> > > user = Membership.GetUser(bruker)
> > >
> > > user.Email = CType(CType(sender,
> > > GridView).Rows(e.RowIndex).Cells(4).Controls(0), TextBox).Text
> > > MsgBox(user.Email)
> > > MsgBox(bruker)
> > >

> >

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
'System.Web.Security.MembershipUser.MembershipUser()' is inaccessibledue to its protection level CSharpner ASP .Net Security 1 05-27-2008 05:51 AM
updating Membershipuser.Email Jeff ASP .Net 2 03-25-2008 07:43 PM
error when getting email of membershipuser Cliff ASP .Net 2 02-14-2007 03:40 PM
email-adress Courtis Joannis Python 1 02-24-2005 12:53 PM
mydoom is using microsoft email adress barry crowley Computer Support 23 02-09-2004 05:27 PM



Advertisments