Hi All,
Limited to one textbox, how do I make it so that only numbers can be entered?
Additionally, I'd like to add another restriction where the number entered must be less than the value of another textbox.
Thanks so much for the help!
Hi All,
Limited to one textbox, how do I make it so that only numbers can be entered?
Additionally, I'd like to add another restriction where the number entered must be less than the value of another textbox.
Thanks so much for the help!
Perhaps.
Please Login or Register to view this content.
If posting code please use code tags, see here.
Norie,
Thank you! They both worked like a charm!
A follow up question which might be a bit tougher. I have 3 combo boxes with dropdowns to select the date. Is there a way to write a similar restriction code so that the concatenated value of the three combo boxes is greater than today's date (which is listed in another textbox if that helps)?
I tried this but it didn't function correctly:
Please note that the code for the date textbox is:Please Login or Register to view this content.
Thank you for the help, it's great.Please Login or Register to view this content.
What's in the month combo?
In the userform, there are three comboboxes in a line. Each one has a dropdown list. The first has numbers for days of the month, the second lists the months, and third lists a 20 year range.
Try this.
Please Login or Register to view this content.
Perfect! Thank you very much Norie
Hi again,
After doing some further testing, the date restriction isn't working. In the form below (as less than today), it accepts any date:
When it appears as greater than today:Please Login or Register to view this content.
then it won't accept any date.Please Login or Register to view this content.
Thanks for the help.
Why have you used Val?
That's probably only going to return the first part of the date.
That will be month or date, or even year, depending on the format of the date in the textbox.
Try using CDate or DateValue instead.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks