By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,969 Members | 1,522 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,969 IT Pros & Developers. It's quick & easy.

Custom profile (vb.net assembly)

P: n/a
Hi,

In an assembly I have created a class like this:

<Serializable()_
Public Class Profile : Inherits System.Web.Profile.ProfileBase

'some private vars and public properties

End Class

In the web.config I have the following:

<profile inherits="CompanyName.Web.Profile" />
<sessionState cookieless="true" />

And I am able to retrieve the profile with:

Public Shared ReadOnly Property Profile() As Web.Profile
Get

Return CType(System.Web.HttpContext.Current.Profile, Web.Profile)

End Get
End Property

I am perfectly able to access the profile via the shared property with
each page request, but the profile is not stored in any way. Upon each
page request the Profile is created again (I have some code in the Sub
New which inserts a record in a database, and upon each pagerequest a
new record is inserted), while I thought the class would be saved during
the complete session, even if a user is not authenticated.

Am I missing something here? Do I not fully understand something?

I hope someone can help me out. Thank you very much in advance!

Nano
Jun 7 '07 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.