views:

100

answers:

1

Hi,

I have a built-in Membership system in ASP.NET and I handle member data with Profiles in web.config.

I would like to add an Event Calendar where a member could add notes to any day he wants but I don't know how to integrate the Calendar control with the existing Membership system.

I can't query a database because I don't handle member login credentials manually, Login control does that for me so I would have to connect the Calendar with the existing ASPNETDB.MDF Membership database but I'm clueless.

A: 

If you are using built-in sql membership provider then it is easier. You can get Logged-in user and access database using that.

object id= Membership.GetUser(Page.User.Identity.Name).ProviderUserKey;

Now yo can store calendar data in table and link user with his calendar with his id (which is GUID).

EDIT:- Here are some links for exploring membership further.

  1. Patterns and Practices group paper

  2. How to video on setting up membership

  3. In depth article at 4guysatrolla by Scott Mitchell

TheVillageIdiot
Thank you for your answer but I'm kind of a beginner in ASP.NET. Can you point to more resources on this subject? I appreciate the piece of code you provided but I don't know how would I use that. Where can I find more examples on the internet?Basically what I would have to do is create another table in ASPNETDB.MDF and relate it to another (?) table in the database and then connect the user (I know how to get the username in asp.net) and pull data. But how would I do that if I don't know member password?