Les Isaacs
Registered User.
- Local time
- Today, 06:02
- Joined
- May 6, 2008
- Messages
- 186
Hi All
We have an access routine that creates and populates an excel workbook, and adds lots of validation - typically:
There is one particular column of data where I want the validation to check whether the value is exactly divisible by 473 - i.e. MOD 473 = 0. Can this be done with validation, and if so what would be on the .Add Type:= line?
Hope someone can help.
Many thanks
Les
We have an access routine that creates and populates an excel workbook, and adds lots of validation - typically:
Code:
1220 With objSheet.range("AM9:AM" & lngRowCount - 2).Offset(0, ColOffset).Validation
1230 .Add type:=xlValidateWholeNumber, AlertStyle:=xlValidAlertStop, Operator:=xlBetween, Formula1:="1", Formula2:="11"
1240 .IgnoreBlank = False
1250 .InputTitle = "Pay period"
1260 .ErrorTitle = "Invalid period number"
1270 .ErrorMessage = "You must enter a period number between 1 and 11."
1280 End With
Hope someone can help.
Many thanks
Les
Last edited by a moderator: