473,854 Members | 1,865 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Plz Help : Want to clear Email,Question, Answer TextBoxes in CreateUserWizar d control

2 New Member
Hello

I am new to ASP.NET. I am using CreateUserWizar d control to register & create a user. I am using Membership API. I have a Cancel button on the second step of CreateUserWizar d control alongwith Create User button & Previous button. Actually, i have added some more textboxes on the default control for taking user's personal information. The problem is that when i call the below mentioned code all textboxes for user's personal information gets cleared but not the default controls on the CreateUserWizar d control which takes user's login ,Email, Security question, answer's information. My code is as follows:

protected void CreateUserWizar d2_CancelButton Click(object sender, EventArgs e)
{//Calling a function & passing all the createuserwizar d controls
DisplayControl( CreateUserWizar d2.CreateUserSt ep.Co ntentTemplateCo ntainer.Control s);
fstname.Focus() ;
}

private void DisplayControl( ControlCollecti on Controls)
{ //recusive routine that can go through the entire control hierarchy
//making empty all textbox controls except with id=username
foreach (System.Web.UI. Control control in Controls)
{
if (control is System.Web.UI.W ebControls.Text Box )
{
if (((System.Web.U I.WebControls.T extBox)control) .ID != "UserName")
((System.Web.UI .WebControls.Te xtBox)control). Text = "";
}
if (control.Contro ls != null)
{
DisplayControl( control.Control s);
}
}

}
Apr 7 '08 #1
0 1457

Sign in to post your reply or Sign up for a free account.

Similar topics

1
2185
by: Phil | last post by:
I would like to make the CreateUserWizard's security question box display as a databound (xml file) dropdownlist. I can make the dropdownlist display by using a contenettemplate, but I can't get the databinding to work. When I reference the control I receive an error saying it doens't exist. I assume the control is buried within the CreateUserWizard, but I can't seem to find it. Thanks, Phil
1
1532
by: J.G. | last post by:
I have set up my web application to utilize an ADAM membership provider. Everything is going well, except I do not wish to utilize the built-in PasswordRecovery control (I don't want the randomly generated password emailed to the user). I want to ask the user the security question, check the answer, and then allow them to immediately change their password. By utilizing the built-in CreateUserWizard, the security answer is...
3
1988
by: Ben R. | last post by:
Seems like CreateUserWizard flat out ignores StartNavigationTemplate. Not sure why the designer bothers to offer for you to edit it, but even when you specifiy this, it doesn't seem to be used. Is this simply inherited from Wizard? Seems the only Navigation that this step will pay attention to is a CustomNavigationTemplate. Does this step simply not fall under the category of StartNavigationTemplate? -Ben
2
2260
by: Learner | last post by:
Hello, I have defined another textbox control in the CreateUserWizard control and this is how I am trying to get the value of it in the code behind page is below im myStep As CreateUserWizardStep = New CreateUserWizardStep Dim DealerShipIDvalue As TextBox = myStep.ContentTemplateContainer.FindControl("_txtDealerShipID") Dim dealer As String dealer = Server.HtmlEncode(DealerShipIDvalue.Text)
0
1109
by: John Hall | last post by:
We are using Visual Web Developer 2005 Express and the ASP.NET administration tool to create users. After we implemented <asp:passwordrecovery ... /> new passwords are emailed to the user instead of the original one. I guess if we save them in clear text instead of hashed, we can be emailed the original password. Question: How to have the ASP.NET administration tool and the asp:createUserWizard control to use only clear text passwords so we...
0
2604
by: Smokey Grindle | last post by:
I am using the user creation wizard in asp.net 2.0 and using it to send the user an email message when their account is created, well this works great if the address is a valid mailbox, but when it is not it throws an exception (shown below) how do i prevent this? Description: System.Web.HttpUnhandledException: Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> System.Net.Mail.SmtpFailedRecipientException: Mailbox...
7
1269
by: Jonathan Wood | last post by:
I'm using ASP.NET membership functionality. My problem is that I think I'd rather have each user account keyed on an email instead of a user name. My main problem with user names is that duplicates become likely and I don't want people to have to enter a bunch of different user names before a unique one is found. I know I can change the prompt of the login control to read email instead of username. Has anyone done this? Anything else I...
3
4630
by: Vincent | last post by:
Hi, With this CreateuserWizard code, i have two problems: 1) when email is left empty ="email not valid." and not "E-mailadres is required." (never shown). When is "E-mailadres is required." shown? 2) anything as email is accepted: "This is not a valid emailaddress" is never shown. Do i have to put a Regularexpressionvalidator control myself?
4
3827
by: gurufordy | last post by:
Hello. Trying to use the ASP.net user functionality but it keeps failing on me. I have created a login and registration page for my site. When you fill in the registration form it should send a confirmation email with a link to activate the account. Nothing hi-tech here. However, it fails to send the email and provides the following error message: Transaction failed. The server response was: sorry, the sender name and auth login doesn't...
0
9899
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
11024
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10740
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
7909
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
7076
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5937
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4550
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
4149
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3182
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.