I have a frame (option group) inside a form with options Monday - Sunday. How would I disable the user from being able to select for example the option Monday if a field on the form equals a certain criteria?
vbMonday is a VB constant for 2
so, I'm not sure what it is you're after. But here is an example using the VB Constants
Select Case DatePart("w",Date)
Case vbSunday 'returns 1 for Sunday
Case vbMonday 'returns 2 for Monday
Case vbTuesday 'returns 3 for Tuesday
Case vbWednesday 'returns 4 for Wednesday
Case vbThursday 'returns 5 for Thursday
Case vbFriday 'returns 6 for Friday
Case vbSaturday 'returns 7 for Saturday
End Select
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.