I have to check to see if an archive is updated or not, I take the date from the archive and compare it with today's date keeping in mind that the archive is updated only 4 times a week on Tuesday, Thursday, Friday and Saturday after 8.30 pm

But If I made dow(date()) give me 4 and not 3 ( 23.10.2024) see the picture how I must correct the function ?
Function CheckEstrazione()
local oDbf
local dDataEstrazione
local lold:=.t.
local oTimer
local nMartedi:= 2
Local nGiovedi:= 4
local nVenerdi:= 5
local nSabato := 6
local nDayarchive,nDaytoday
oDbf := TArchivioLotto():New()
oDbf:SetOrder(1 )
oDbf:goBottom()
dDataEstrazione:= oDbf:data
oDbf:close()
//determino numero giorno
nDayarchive:= dow(dDataEstrazione) //estrazione salvata
nDaytoday:= dow(date()) //oggi
IF nDaytoday = nMartedi
IF nDayarchive < nDayToday
lOld:=.f.
Endif
Endif
IF nDaytoday = nGiovedi
IF nDayarchive < nDayToday
lOld:=.f.
Endif
Endif
IF nDaytoday = nVenerdi
IF nDayarchive < nDayToday
lOld:=.f.
Endif
Endif
IF nDaytoday = nSabato
IF nDayarchive < nDayToday
lOld:=.f.
Endif
Endif
return lOld
But If I made dow(date()) give me 4 and not 3 ( 23.10.2024) see the picture how I must correct the function ?
Since from 1991/1992 ( fw for clipper Rel. 14.4 - Momos)
I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com
I use : FiveWin for Harbour March-April 2024 - Harbour 3.2.0dev (harbour_bcc770_32_20240309) - Bcc7.70 - xMate ver. 1.15.3 - PellesC - mail: silvio[dot]falconi[at]gmail[dot]com