473,327 Members | 2,118 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,327 software developers and data experts.

Membership Provider

Sorry for cross post, forgot to include aspnet in orinal...

Thanks in advance for any assistance.

I'm in the process of implementing custom RoleProvider & Membership Provider
objects and have run into a snag with the Membership Provider.

It seems many of the MembershipUser properties are read-only. This seems,
well stupid, IMO.

I can override these in a class that inherits from MembershipUser and set
them via parameters in the constructor, but that's a lot of work for what
seems should be read-write properties, especially when implementing a custom
provider for another data store. For example, IsLockedOut is read
only?Shouldn't I be able to write to this property when returning a
MembershipUser for the GetUser method?

My question is, is there any other way to access these read only properties?
Have I missed something obvious?

Thanks again,

Morgan
Dec 6 '05 #1
3 2418
Hi Morgan,

Welcome to ASPNET newsgroup.
As for the MembershipUser class, yes, it has many properteis defined as
readonly. Based on my understanding, those properties are mainly configured
through administration interfaces(most of such methods are defined in
MembershipProvider class), e.g lock a user when the user created and then
active through updating later(through the
SqlMembershipProvider.UnlockUser()).... And all these information stored in
database should not changed outside by normal client application which use
the membership info.... Client application just need to query these
information through GetUser method(retrieved from backend database
storage).... I think that's the reason the buildin MembershipUser class
marked them as readonly .... Of course, we can override or replace them
to all read/writeable in our custom membership framework....

Thanks,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)


--------------------
| From: "Morgan" <ab**@senditon.com>
| Subject: Membership Provider
| Date: Tue, 6 Dec 2005 12:15:29 -0500
| Lines: 25
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
| X-RFC2646: Format=Flowed; Original
| Message-ID: <#H**************@TK2MSFTNGP12.phx.gbl>
| Newsgroups: microsoft.public.dotnet.framework.aspnet
| NNTP-Posting-Host: 168-215-79-61.gen.twtelecom.net 168.215.79.61
| Path: TK2MSFTNGXA02.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFT NGP12.phx.gbl
| Xref: TK2MSFTNGXA02.phx.gbl
microsoft.public.dotnet.framework.aspnet:363128
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
|
| Sorry for cross post, forgot to include aspnet in orinal...
|
| Thanks in advance for any assistance.
|
| I'm in the process of implementing custom RoleProvider & Membership
Provider
| objects and have run into a snag with the Membership Provider.
|
| It seems many of the MembershipUser properties are read-only. This seems,
| well stupid, IMO.
|
| I can override these in a class that inherits from MembershipUser and set
| them via parameters in the constructor, but that's a lot of work for what
| seems should be read-write properties, especially when implementing a
custom
| provider for another data store. For example, IsLockedOut is read
| only?Shouldn't I be able to write to this property when returning a
| MembershipUser for the GetUser method?
|
| My question is, is there any other way to access these read only
properties?
| Have I missed something obvious?
|
| Thanks again,
|
| Morgan
|
|
|

Dec 7 '05 #2
Thanks, Steven.

"Steven Cheng[MSFT]" <st*****@online.microsoft.com> wrote in message
news:iC****************@TK2MSFTNGXA02.phx.gbl...
Hi Morgan,

Welcome to ASPNET newsgroup.
As for the MembershipUser class, yes, it has many properteis defined as
readonly. Based on my understanding, those properties are mainly
configured
through administration interfaces(most of such methods are defined in
MembershipProvider class), e.g lock a user when the user created and then
active through updating later(through the
SqlMembershipProvider.UnlockUser()).... And all these information stored
in
database should not changed outside by normal client application which use
the membership info.... Client application just need to query these
information through GetUser method(retrieved from backend database
storage).... I think that's the reason the buildin MembershipUser class
marked them as readonly .... Of course, we can override or replace them
to all read/writeable in our custom membership framework....

Thanks,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)


--------------------
| From: "Morgan" <ab**@senditon.com>
| Subject: Membership Provider
| Date: Tue, 6 Dec 2005 12:15:29 -0500
| Lines: 25
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
| X-RFC2646: Format=Flowed; Original
| Message-ID: <#H**************@TK2MSFTNGP12.phx.gbl>
| Newsgroups: microsoft.public.dotnet.framework.aspnet
| NNTP-Posting-Host: 168-215-79-61.gen.twtelecom.net 168.215.79.61
| Path: TK2MSFTNGXA02.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFT NGP12.phx.gbl
| Xref: TK2MSFTNGXA02.phx.gbl
microsoft.public.dotnet.framework.aspnet:363128
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
|
| Sorry for cross post, forgot to include aspnet in orinal...
|
| Thanks in advance for any assistance.
|
| I'm in the process of implementing custom RoleProvider & Membership
Provider
| objects and have run into a snag with the Membership Provider.
|
| It seems many of the MembershipUser properties are read-only. This
seems,
| well stupid, IMO.
|
| I can override these in a class that inherits from MembershipUser and
set
| them via parameters in the constructor, but that's a lot of work for
what
| seems should be read-write properties, especially when implementing a
custom
| provider for another data store. For example, IsLockedOut is read
| only?Shouldn't I be able to write to this property when returning a
| MembershipUser for the GetUser method?
|
| My question is, is there any other way to access these read only
properties?
| Have I missed something obvious?
|
| Thanks again,
|
| Morgan
|
|
|

Dec 8 '05 #3
You're welcome Norgan,

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
--------------------
| From: "Morgan" <no****@spam.com>
| References: <#H**************@TK2MSFTNGP12.phx.gbl>
<iC**************@TK2MSFTNGXA02.phx.gbl>
| Subject: Re: Membership Provider
| Date: Wed, 7 Dec 2005 21:15:20 -0500
| Lines: 89
| X-Priority: 3
| X-MSMail-Priority: Normal
| X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
| X-RFC2646: Format=Flowed; Original
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
| Message-ID: <OF**************@TK2MSFTNGP14.phx.gbl>
| Newsgroups: microsoft.public.dotnet.framework.aspnet
| NNTP-Posting-Host: 12-222-91-80.client.insightbb.com 12.222.91.80
| Path: TK2MSFTNGXA02.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFT NGP14.phx.gbl
| Xref: TK2MSFTNGXA02.phx.gbl
microsoft.public.dotnet.framework.aspnet:363534
| X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
|
| Thanks, Steven.
|
| "Steven Cheng[MSFT]" <st*****@online.microsoft.com> wrote in message
| news:iC****************@TK2MSFTNGXA02.phx.gbl...
| > Hi Morgan,
| >
| > Welcome to ASPNET newsgroup.
| > As for the MembershipUser class, yes, it has many properteis defined as
| > readonly. Based on my understanding, those properties are mainly
| > configured
| > through administration interfaces(most of such methods are defined in
| > MembershipProvider class), e.g lock a user when the user created and
then
| > active through updating later(through the
| > SqlMembershipProvider.UnlockUser()).... And all these information
stored
| > in
| > database should not changed outside by normal client application which
use
| > the membership info.... Client application just need to query these
| > information through GetUser method(retrieved from backend database
| > storage).... I think that's the reason the buildin MembershipUser
class
| > marked them as readonly .... Of course, we can override or replace
them
| > to all read/writeable in our custom membership framework....
| >
| > Thanks,
| >
| > Steven Cheng
| > Microsoft Online Support
| >
| > Get Secure! www.microsoft.com/security
| > (This posting is provided "AS IS", with no warranties, and confers no
| > rights.)
| >
| >
| >
| >
| >
| >
| > --------------------
| > | From: "Morgan" <ab**@senditon.com>
| > | Subject: Membership Provider
| > | Date: Tue, 6 Dec 2005 12:15:29 -0500
| > | Lines: 25
| > | X-Priority: 3
| > | X-MSMail-Priority: Normal
| > | X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
| > | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
| > | X-RFC2646: Format=Flowed; Original
| > | Message-ID: <#H**************@TK2MSFTNGP12.phx.gbl>
| > | Newsgroups: microsoft.public.dotnet.framework.aspnet
| > | NNTP-Posting-Host: 168-215-79-61.gen.twtelecom.net 168.215.79.61
| > | Path: TK2MSFTNGXA02.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFT NGP12.phx.gbl
| > | Xref: TK2MSFTNGXA02.phx.gbl
| > microsoft.public.dotnet.framework.aspnet:363128
| > | X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
| > |
| > | Sorry for cross post, forgot to include aspnet in orinal...
| > |
| > | Thanks in advance for any assistance.
| > |
| > | I'm in the process of implementing custom RoleProvider & Membership
| > Provider
| > | objects and have run into a snag with the Membership Provider.
| > |
| > | It seems many of the MembershipUser properties are read-only. This
| > seems,
| > | well stupid, IMO.
| > |
| > | I can override these in a class that inherits from MembershipUser and
| > set
| > | them via parameters in the constructor, but that's a lot of work for
| > what
| > | seems should be read-write properties, especially when implementing a
| > custom
| > | provider for another data store. For example, IsLockedOut is read
| > | only?Shouldn't I be able to write to this property when returning a
| > | MembershipUser for the GetUser method?
| > |
| > | My question is, is there any other way to access these read only
| > properties?
| > | Have I missed something obvious?
| > |
| > | Thanks again,
| > |
| > | Morgan
| > |
| > |
| > |
| >
|
|
|

Dec 8 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: John | last post by:
Hi I was working fine with create user wizard and the default membership provider. I have now customised the membership provider as per attached web.config. The create user wizard picks up the...
3
by: ad | last post by:
I have create a custom membership provider. The common usage of custom membership is set it as default Membership Provider win web.config, and use login controls with it. How can I use custom...
9
by: Paul Keegstra | last post by:
Hi, I am currently working on an asp.net 2.0 web site that is a replacement of a classic asp web site. The current web site uses a Commerce Server 2002 database for storing user information. ...
2
by: Balaji | last post by:
Hi All, Can I use more than one membership provider for a given website? I understand only one of them could be default one. If yes, then how to programmatically access the other membership...
3
by: ryan.mclean | last post by:
Hello everyone, I am wondering, can the membership provider be changed at runtime? Perhaps the connectionStringName? I would like to use a different database based on the server the site is...
4
by: thomas | last post by:
Hello All, How to change the default Membership Provider during the runtime? I know I can reference any provider I want, e.g.: provider = Membership.Providers but the question is how to...
4
by: =?Utf-8?B?Q2hyaXMgQ2Fw?= | last post by:
I have been having some trouble with implementing a custom Membership Provider. We have a custom data store and business logic that pulls user information. I need some level of functionality...
1
by: Ben | last post by:
Hi, When an anonymous user has created an new account (with the CreateUserWizard control), i want to let asp.net generate a password and to send it to the address of the email provided by the...
6
by: Jonathan Wood | last post by:
Although this will be a challenge at my level of ASP.NET knowledge, I'm thinking I should implement my own membership provider class. Looking over the methods I must implement, a number of...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.