Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
TextBox Values
Hello!,
How I can limit textbox (or combo) from accepting only numbers and Minimum is zero and maximum is Number of days in a specific month? say for eg. In comboBox1 i select february then textBox1 shoul accept only from 0 to 28 or in case of april 0 to 30, May 0 to 31 etc... based on the value in textbox1 textbox2 is calculated, so textbox1 should not be allowed to be empty to avoid an error thanks |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
TextBox Values
The simplest way for beginners is to validate the data once it is entered. Private Sub TextBox1_Change() t = TextBox1.Text If Not IsNumeric(t) Then MsgBox "Non numeric character " End Sub For experts, each keystroke can be monitored. -- raypayette ------------------------------------------------------------------------ raypayette's Profile: http://www.excelforum.com/member.php...o&userid=29569 View this thread: http://www.excelforum.com/showthread...hreadid=566924 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Using a DO loop to add values into a textbox | Excel Programming | |||
Textbox values | Excel Programming | |||
How do I add TextBox.values? | Excel Programming | |||
How do I add TextBox.values? | Excel Discussion (Misc queries) | |||
How do I add TextBox.values? | Excel Worksheet Functions |