SELECT("Serv_det") SELECT * From Serv_det WHERE REMIND_DATE = DATE() INTO CURSOR TEMP SELECT("TEMP") GO TOP IF !EOF() .OR. !BOF() IF lOnline nTimer = 10000 lContinue = .F. ELSE nTimer = 0 ENDIF ELSE nTIMER = 0 ENDIFOn my Timer's Timer Event, I have the code below...
IF lOnline IF nTimer = 10000 IF !USED("Serv_det") USE G:\Helpdesk\data\Serv_det IN 0 ORDER TAG So_nbr SHARED ELSE SELECT("Serv_det") SET ORDER TO TAG SO_NBR ENDIF SELECT("SERV_DET") GO TOP LOCATE FOR !EMPTY(so_nbr) .and. Remind_date = DATE() .And. Done =.F. _So_nbr = ALLTRIM(so_nbr) _Custid = ALLTRIM(custid) _Custname = ALLTRIM(custname) _last_update = Last_update DO FORM Show-POPUP WITH _so_nbr,_custid,_custname,_last_update IF lContinue DO WHILE !EOF() CONTINUE IF FOUND() _so_nbr = ALLTRIM(so_nbr) _Custid = ALLTRIM(custid) _Custname = ALLTRIM(custname) _last_update = Last_update DO FORM SHOW-POPUP WITH _so_nbr,_custid,_custname,_last_update ENDIF ENDDO ENDIF ENDIFThis code will check all Service where last_update is the current date and it has criteria e.g Unfinished job. A form will pop-up where in user has to update. lContinue is true if user click Update button. It will show all unfinished services.