473,405 Members | 2,445 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,405 software developers and data experts.

Membership class api

Hello,
I am using the Membership control in my asp.net application. When a person
registers, I set the account to not active.

CreateUserWizard1.Enabled = false;

Then I send them an email with a link for them to click on to activate their
account.

Got it all working, but do not know how to programaticly activate the
account.
I have to open the ASP.NET configuration web site and manually go to the
users account and click on 'active'.

How can I do this using C#?

Remember, when they click on the link in their email, it will open a page on
my site, but they are not logged in. So I need some way to look up the user
in my database, and then tell the membership api to find that user and set
them to active.

Thanks for your help...
Michael

Aug 24 '06 #1
2 1734
Michael,
This is an ASP.NET question. If you ask it over at the asp.net group, either
I or somebody else will be happy to respond there.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"Michael" wrote:
Hello,
I am using the Membership control in my asp.net application. When a person
registers, I set the account to not active.

CreateUserWizard1.Enabled = false;

Then I send them an email with a link for them to click on to activate their
account.

Got it all working, but do not know how to programaticly activate the
account.
I have to open the ASP.NET configuration web site and manually go to the
users account and click on 'active'.

How can I do this using C#?

Remember, when they click on the link in their email, it will open a page on
my site, but they are not logged in. So I need some way to look up the user
in my database, and then tell the membership api to find that user and set
them to active.

Thanks for your help...
Michael
Aug 24 '06 #2
Check out and use the aspnet_Membership_UnlockUser stored procedure and
others that were created and installed in your database when Membership was
configured by aspnet_regiis. Those stored procedures are how the Website
Administrator gets stuff done and we can reuse them in our own code.

You can learn a lot more about using C# to call stored procedures by
submitting the following search query to Google...

call stored procedure C# site:msdn2.microsoft.com

Peter's got a good point though about asking questions in other newsgroups
as you still have some design questions that still need to be answered.

<%= Clinton Gallagher
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/
MAP 43°2'17"N 88°2'37"W : 43°2'17"N 88°2'37"W


"Michael" <Mi*****@discussions.microsoft.comwrote in message
news:FE**********************************@microsof t.com...
Hello,
I am using the Membership control in my asp.net application. When a
person
registers, I set the account to not active.

CreateUserWizard1.Enabled = false;

Then I send them an email with a link for them to click on to activate
their
account.

Got it all working, but do not know how to programaticly activate the
account.
I have to open the ASP.NET configuration web site and manually go to the
users account and click on 'active'.

How can I do this using C#?

Remember, when they click on the link in their email, it will open a page
on
my site, but they are not logged in. So I need some way to look up the
user
in my database, and then tell the membership api to find that user and set
them to active.

Thanks for your help...
Michael

Aug 25 '06 #3

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

Similar topics

3
by: Morgan | last post by:
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...
1
by: Andy | last post by:
Hi, I was wondering if someone could advise on if the following is possible. I have one website that is available to the public using Forms authentication and the Membership class, it...
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...
4
by: =?Utf-8?B?U2FsYW1FbGlhcw==?= | last post by:
Hi, I am trying to play with the Survey manager application provided gracefully by Microsoft at "http://msdn.microsoft.com/vstudio/express/sql/samples/" VB team(so many thanks), compiled the win...
0
by: Jay Pondy | last post by:
I added a Company field to the aspNet_Users table and then followed along with the MSDN docs on How to Implement a Custom Membership User by creating my inherited class from the...
3
by: daokfella | last post by:
I'm just starting to dive into the new membership stuff and wondering if it is possible to customize the default membership architecture in ASP.Net 2.0 to do the following: Instead of UserName...
2
by: David Lozzi | last post by:
Howdy, My biggest annoyance with the membership class is that i cannot seem to get to it in my master files. I'd like to setup my master file to check for whether or not the current user is...
3
by: Glenn | last post by:
My current classic-ASP site has users, projects, roles and the 2.0 membership looks like a perfect fit, but I'm having trouble finding examples of how to have users that belong to different...
1
by: mazdotnet | last post by:
Hi all, I just found out that ASP.NET membership does not have a method to lock accounts (only Unlock user) See http://forums.asp.net/p/825946/825946.aspx Question was 'I understand that...
2
by: mazdotnet | last post by:
Hi all, I just found out that ASP.NET membership does not have a method to lock accounts (only Unlock user) See http://forums.asp.net/p/825946/825946.aspx Question was 'I understand that the...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.