>Experiencing some wierdness with a new app written in VFP 8. I have traced the offending line of code where I am replace a field value with datetime(). However, I am receiving the above error. I have tablevalidate set to 0 for the program and even inserted a "set tablevalidate to 0" roght before the line of code but am still getting this error.
>
>The affected table is a free table which has been opened shared right above this code.
>
>
>The code is below...
>
>lcLw2000Dir = oApp.cAppDir
>CD &lcLw2000Dir
>
>SET TABLEVALIDATE TO 0
>IF USED('armaconf')
> SELECT armaconf
>ELSE
> USE armaconf.DBF IN 0 SHARED
> SELECT armaconf
>ENDIF
>
>* The culprit line is below
>REPLACE armaconf.lastbudt WITH DATETIME()
>
>USE
>
>Any ideas?
>
>Wayne Frenck
It appears from your code that you are in the armaconf work area before your replace. Note that the use of the alias ARMACONF in your replace statement does nothing though. The REPLACE is acting upon the current work area - I would use :
REPLACE lastbudt WITH DATETIME() IN armaconf
to be sure that the REPLACE is acting on armaconf. Or you could WAIT ALIAS() WINDOW before the REPLACE to ensure that you are in the right work area.
Cheers,
Jamie
Cheers,
Jamie