I have a database where a user selects on a form, a year and a range of periods (months in the year) on which to run a report. The periods are between 1 and 12. Validation code checks to make sure the From value is less than the To value. Example: to see data from July through October the user would enter 7 in the From field and 10 in the To field. If the To field value was less than 7 a message would pop up telling them of the error.
Here is the validation code:
If Me.cboFPFrom > Me.cboFPTo Then
MsgBox "Period From value must be less than the Period To value."
blnValidation = True
Me.cboFPFrom.SetFocus
GoTo EndValidation
End If
When I step through the code Me.cboFPFrom shows the value "7" and Me.cboFPTo shows "10". The intriquing part of this is the code has worked just fine for the last 18 months. So what has changed? Here where I work this last month the IT group installed more security updates (which happens often actually) and a patch to allow everyone to read and write to Office 2007 files (we use Office 2003). So now suddenly the logical evaluation is backward. Any ideas?!!
Thanks in advance,
John
Here is the validation code:
If Me.cboFPFrom > Me.cboFPTo Then
MsgBox "Period From value must be less than the Period To value."
blnValidation = True
Me.cboFPFrom.SetFocus
GoTo EndValidation
End If
When I step through the code Me.cboFPFrom shows the value "7" and Me.cboFPTo shows "10". The intriquing part of this is the code has worked just fine for the last 18 months. So what has changed? Here where I work this last month the IT group installed more security updates (which happens often actually) and a patch to allow everyone to read and write to Office 2007 files (we use Office 2003). So now suddenly the logical evaluation is backward. Any ideas?!!
Thanks in advance,
John