hi, everyone
i found a code for textoboxes pass only numbers to sheet
but i have 105 textboxes,Please Login or Register to view this content.
so i want a simple way to numbers only in textboxes
thanx
hi, everyone
i found a code for textoboxes pass only numbers to sheet
but i have 105 textboxes,Please Login or Register to view this content.
so i want a simple way to numbers only in textboxes
thanx
Use Code-Tags for showing your code :
Please mark your question Solved if there has been offered a solution that works fine for you
If You like solutions provided by anyone, feel free to add reputation using STAR *
HaroonSid:
There are 2 ways...
#1: You still make a Exit event for every box, but each calls ONE sub that does the checking... You will need the same Exit for every box.
or #2: You add all the textboxes to a class, but you would need a class module and I suspect that is a bit advanced for now. If you want to post the file then I could see if I can make some time to do it for you, if you tell me which textboxes on which form need to behave this way.Please Login or Register to view this content.
Please help by:
Marking threads as closed once your issue is resolved. How? The Thread Tools at the top
Any reputation (*) points appreciated. Not just by me, but by all those helping, so if you found someone's input useful, please take a second to click the * at the bottom left to let them know
There are 10 kinds of people in this world... those who understand binary, and those who don't.
Add this to a Class Module. Change the class name from Class1 to clsNumericTextBox. Code only allows for Numeric keys to be entered into any textbox on userform.
Add this to your Userform ModulePlease Login or Register to view this content.
Please Login or Register to view this content.
Last edited by mike7952; 01-25-2017 at 01:55 PM.
Thanks,
Mike
If you are satisfied with the solution(s) provided, please mark your thread as Solved.
Select Thread Tools-> Mark thread as Solved.
@mike, nice code
Thanx A lot for the quick response both of you
@Arkadi
thanx a lot for quick and good knowledge for me of multiple method to do the same thing
@mike7952
your code is working as i need but there is one lose point that its not picking the .125 (decimals) otherwise if working
plz solve the decimals,
because i need to put sometime decimal vlaues
thanx a lot both of you once again
In the Class Module just add 46
Please Login or Register to view this content.
Yes
perfectly
thanx, very very thanx
dear @mike7952
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks