Click here to Skip to main content
15,074,377 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Greetings for the day,
I did make user control for date picker on my register form now i want to delete value of that control after submittion
mydatepicker.value.clear() can i use ??
Member 11221185 29-May-15 2:02am
After completing the code of save button you can just set text box value like:
Textbox1.text = "";

yes you can use mydatepicker.value.clear(). it will work.
Member 10874581 29-May-15 2:23am
nt working..
You can use below code to reset

public static void ClearTextBoxes(Control parent)
     foreach (Control c in parent.Controls) {
       if (c.GetType() == typeof(TextBox))
         ((TextBox)(c)).Text = string.Empty;

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900