coolcatkelso
Registered User.
- Local time
- Today, 23:58
- Joined
- Jan 5, 2009
- Messages
- 279
Hiya
I have a popup reminder on my form splash screen that should only display if there are any work orders with "Awaiting Start" in the related tables, here is the code
But, I did a test run and found that if I create a new work order and its category is "Awaiting Start" the reminder picks it up.. If I go in and change the status to "Job Complete", save and refresh everything, then the reminder still pops up with no records.. All I get is the message "There are new jobs ready to start, View jobs? Yes / No" If I click yes, i just get a blank form with (NEW) for the ID field, but I shouldn't actually get any popup
Am I missing something?
________
MOTOR ENGINEERING & MANUFACTURING NORTH AMERICA
I have a popup reminder on my form splash screen that should only display if there are any work orders with "Awaiting Start" in the related tables, here is the code
Code:
Private Sub Form_Load()
Dim intStore As Integer
intStore = DCount("[WorkorderID]", "[Workorders]", "[StartDate] <=Now()+4 AND [StartDate]")
If intStore = 0 Then
Exit Sub
Else
If MsgBox("There is new jobs booked to start" & _
vbCrLf & vbCrLf & "Would you like to see these now?", _
vbYesNo, "You have new jobs ready to start...") = vbYes Then
DoCmd.Minimize
DoCmd.RunMacro "StartJob"
Else
Exit Sub
End If
End If
End Sub
But, I did a test run and found that if I create a new work order and its category is "Awaiting Start" the reminder picks it up.. If I go in and change the status to "Job Complete", save and refresh everything, then the reminder still pops up with no records.. All I get is the message "There are new jobs ready to start, View jobs? Yes / No" If I click yes, i just get a blank form with (NEW) for the ID field, but I shouldn't actually get any popup
Am I missing something?
________
MOTOR ENGINEERING & MANUFACTURING NORTH AMERICA
Last edited: