I was wondering if anyone might have a way of work around for what I am trying to do.
I have a subform based on a query that looks to see if a product is good. If it it good it is marked by a time stamp. After the time expires the code marks the product is no longer good, marks taht it needs to be resampled and the DateTime it needs resampled.
The code has been working great until one little snag. When there is no longer any sample to run the code against I get the '2427' Runtime error. You entered an expression that has no value.
This makes sense but I have been unable to figure out how to see if the field is there to run the code against. I have banged my head on this for a couple weeks now and woudl love some help or suggestions if anyone has any.
I will post the code I am using.
Thanks in advance.
Private Sub Form_Timer()
Me.Text46 = Now
Me.Form.Requery
If Me.txtMinsGood.Value >= 10080 Then
Me.dtmDateNeedsResampled = Now
Me.ysnNeedsResampled = True
Me.ysnOKtoUnload = False
End If
End Sub
I basically just run the code once a minute.
I have a subform based on a query that looks to see if a product is good. If it it good it is marked by a time stamp. After the time expires the code marks the product is no longer good, marks taht it needs to be resampled and the DateTime it needs resampled.
The code has been working great until one little snag. When there is no longer any sample to run the code against I get the '2427' Runtime error. You entered an expression that has no value.
This makes sense but I have been unable to figure out how to see if the field is there to run the code against. I have banged my head on this for a couple weeks now and woudl love some help or suggestions if anyone has any.
I will post the code I am using.
Thanks in advance.
Private Sub Form_Timer()
Me.Text46 = Now
Me.Form.Requery
If Me.txtMinsGood.Value >= 10080 Then
Me.dtmDateNeedsResampled = Now
Me.ysnNeedsResampled = True
Me.ysnOKtoUnload = False
End If
End Sub
I basically just run the code once a minute.