you can use a
ProfileProvider
( with one implmentation being the SqlProfileProvider class )
to add some custom info about a User.
(Height, Weight, EyeColor as an example)
Is there a way to add custom information to the Application (s) ?
The reason I'm asking is I'd like to have a either an Active (bool/bit)
flag, or a daterange
( StartApplicationDate and EndApplicationDate )
so I can setup my applications, but have them active or automatically be
enabled/disabled on the date.
I"m trying to find the intelligent non-hacky way to implement this feature,
instead of hacking up the default membership provider stuff.
Thanks for any hints.
<profile defaultProvider="SqlProvider">
<providers>
<clear />
<add name="SqlProvider"
type="System.Web.Profile.SqlProfileProvider"
connectionStringName="SqlServices"
applicationName="SampleApplication"
description="SqlProfileProvider for SampleApplication" />
</providers>
<properties>
<add name="Height" />
<add name="Weight" />
<add name="EyeColor" />
</properties>
</profile>
Peter Bromberg [C# MVP] - 26 Jul 2007 19:26 GMT
If you are going to use the buit-in available providers, no. Profile of
course is specifically targeted at users.
However, there is nothing to stop you from keeping such application-specific
data in a table in your database, and writing a quasi "provider" to access
this data when an application is started.
-- Peter
Recursion: see Recursion
site: http://www.eggheadcafe.com
unBlog: http://petesbloggerama.blogspot.com
bogMetaFinder: http://www.blogmetafinder.com
> you can use a
> ProfileProvider
[quoted text clipped - 35 lines]
> </properties>
> </profile>
sloan - 26 Jul 2007 20:32 GMT
Yeah, that is what I was thinking as well.
SqlRoleProvider and SqlMembershipProvider actually look
inheritable-friendly.
........
> If you are going to use the buit-in available providers, no. Profile of
> course is specifically targeted at users.
[quoted text clipped - 48 lines]
>> </properties>
>> </profile>