>LPARAMETERS tcCursor, tcTable, tlUpdateKey >IF VARTYPE(tcCursor) <> 'C' > RETURN .f. >ENDIF >IF VARTYPE(tcTable) <> 'C' > RETURN .f. >ENDIF >IF NOT USED(tcCursor) > RETURN .f. >ENDIF >CURSORSETPROP('Tables', tcTable) >** The next property must include every remote >** field matched with the cursor field. >LOCAL lcFields, lcUpdate, llRetVal >lcFields = '' >lcUpdate = '' >FOR lnI = 1 TO FCOUNT(tcCursor) > IF NOT EMPTY(lcFields) > lcFields = lcFields + ', ' > ENDIF > lcFields = lcFields + FIELD(lnI, tcCursor) + ' ' ; > + tcTable + '.' + FIELD(lnI, tcCursor) > IF UPPER(FIELD(lnI, tcCursor)) == 'KEYID' > IF NOT tlUpdateKey > LOOP > ENDIF > ENDIF > IF NOT EMPTY(lcUpdate) > lcUpdate = lcUpdate + ', ' > ENDIF > lcUpdate = lcUpdate + FIELD(lnI, tcCursor) >ENDFOR >llRetVal = CURSORSETPROP('UpdateNameList', lcFields, tcCursor) >llRetVal = CURSORSETPROP('KeyFieldList', 'KeyID', tcCursor) >** The next property specifies which fields can be updated. >llRetVal = CURSORSETPROP('UpdatableFieldList', lcUpdate, tcCursor) >** The next property enables you to send updates. >llRetVal = CURSORSETPROP('SendUpdates', .T., tcCursor) >llRetVal = CURSORSETPROP('UpdateType', 1, tcCursor) >llRetVal = CURSORSETPROP('WhereType', 1, tcCursor) >RETURN llRetVal >