thanks borislav
I understand you are giving me the second to last date. how would I get the name of the second to last FILE linked with that date?
k
>>this is a followup to a solution I received from Sergey and Naomi (with thanks). It gives the title and date of the last changed database in a directory.
>>
>>I don't know if this is possible but could I select the one BEFORE the last database -
>>The database that always comes up is called tasks.dbf and is actually always s changed. I would like the code to read
>>if the last file is tasks.dbf then show me the one before that and it's date of change.
>>
>>I can make it to the if clause - and even that is probably not the most effective route.
>>
>>
>>if lafielist='tasks.dbf'
>>
>>
>>
>>ltZeroTime = CTOT("00:00:00")
>>= ADIR(laFieList, 'c:\db\prg\menu\*.dbf')
>>FOR i= 1 TO ALEN(laFieList,1)
>>laFieList[i,5] = DTOT(laFieList[i,3]) + (CTOT(laFieList[i,4]) - ltZeroTime)
>>ENDFOR
>>= ASORT(laFieList, 5,0,5)
>>ndate = mdy(lafielist(1,3))
>>ndm = "Last database file change: "+ndate+" "+lafielist
>>
>>
>>tnx
>>k
>
>
>
>...
>ndate = mdy(lafielist[1,3])
>IF ALEN(lafielist, 1 ) > 1
> Secondndate = mdy(lafielist[2,3])
> WAIT WINDOW Secondndate
>ENDIF
>..
>