>>>I have a form with 5 tables in the dataenvironment. The buffermodeoverride is set to 1 for all of the tables.
>>>
>>>The form's init contains:
>>>
>>>set multilocks on
>>>= CURSORSETPROP('Buffering',5, 'biditems' )
>>>= CURSORSETPROP('Buffering',5, 'projects' )
>>>= CURSORSETPROP('Buffering',5, 'projectphases' )
>>>= CURSORSETPROP('Buffering',5, 'lineitemspecs' )
>>>dodefault()
>>>
>>>The form's buffermode = 2
>>>
>>>The form has a pageframe and the pageframe contains a grid.
>>>The grid's recordsource is set
>>>
>>>thisform.df_tabs1.df_page1.grdBiditems.RecordSource = ;
>>>"select * from biditems " + ;
>>>" inner join lineitemspecs " + ;
>>>" on biditems.lineitemid = lineitemspecs.lineitemid " + ;
>>>" where biditems.projectphaseid = val(this.value) " + ;
>>>" into cursor crsTemp readwrite"
>>>
>>>The grid's AfterRowColChange contains
>>>LPARAMETERS nColIndex
>>>
>>>=tableupdate(0,.t.,"biditems")
>>>
>>>
>>>It all seems to work except the edits made in the grid are not being saved back to the biditems table. What am I missing?
>>
>>First, Buffering = 5 is not ROW buffering. It is optimistic Table buffering.
>>Second, you miss to check WHY TableUpdate is not successful:
>>
>>IF NOT tableupdate(0,.t.,"biditems")
>> AERROR(laError)
>> MessageBox(laError[1,2])
>>ENDIF
>>
>
>I know, I originally had it set to 3 and then changed it to 5. I just haven't cleaned up my comments yet (I want to get it working first) shame on me.
>
>Your suggested code does not produce an error. A browse of the cursor shows the values in the cursor but they are not getting to the original table.
OOOOOO, Shame on me! I just watch buffering code and TableUpdate() one. Not see that your grid RecordSource is not BidItems table.
OK, What version of VFP?
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.