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

Resetting Values in TextBoxes

P: 4
Hi,
I need to know how to reset values in 40 textboxes in one go. Mind I am using 8 arrays of text boxes. Please help how to validate them for a rage of values. I am a new learner.
Thanks
Pankaj
Sep 14 '07 #1
Share this Question
Share on Google+
2 Replies


hariharanmca
100+
P: 1,977
Hi,
I need to know how to reset values in 40 textboxes in one go. Mind I am using 8 arrays of text boxes. Please help how to validate them for a rage of values. I am a new learner.
Thanks
Pankaj
I think the way you are going is wrong!

Can you explain your problem with detail? (we can point you better).
Sep 14 '07 #2

pureenhanoi
100+
P: 175
Hi,
I need to know how to reset values in 40 textboxes in one go. Mind I am using 8 arrays of text boxes. Please help how to validate them for a rage of values. I am a new learner.
Thanks
Pankaj
this code will reset values of all textboxes in one form.
Expand|Select|Wrap|Line Numbers
  1. Private cmdReset_Click()
  2. Dim ctrl As Control
  3. On Error Resume Next
  4. For Each ctrl In Me.Controls
  5.   If TypeName(ctrl) = "TextBox" Then
  6.     ctrl.Text = ""
  7.   End If
  8. Next
  9. End Sub
  10.  
Sep 14 '07 #3

Post your reply

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