sbendbuckeye
Active Member
- Joined
- Nov 26, 2003
- Messages
- 440
I have an Excel UserForm with 2 textboxes on it, txtBegDate and txtEndDate. For monthly or semimonthly payrolls they contain the day or days when payroll is processed (eg 1 and 15, 15 and EOM or just 15 for monthly, etc.). If the payroll is weekly then the textboxes need to be dimmed.
In the after update event for the ListBox which allows the user to select the payroll code I have logic similar to this:
txtBegDate.Enabled = IsMonthlyPayroll or IsSemiMonthlyPayroll
The Is functions are boolean and return True or False. Even thougth they are not greyed out they appear to be locked as you cannot give them focus or enter data into them. I'm using ExcelXP if that makes a difference.
In the after update event for the ListBox which allows the user to select the payroll code I have logic similar to this:
txtBegDate.Enabled = IsMonthlyPayroll or IsSemiMonthlyPayroll
The Is functions are boolean and return True or False. Even thougth they are not greyed out they appear to be locked as you cannot give them focus or enter data into them. I'm using ExcelXP if that makes a difference.