save Method
Class: tsbaseform
Expand/Collapse source code of procedure save Source Code
LOCAL laError[AERRORARRAY], ;
      llError

llError = !thisform.WriteBuffer()

IF !llError AND !this.DataChanged()
  RETURN .T.
ENDIF

IF !llError
  llError = !TABLEUPDATE(.T.)
  IF llError
    IF AERROR(laError) > 0
      *-- Let the form's error handler handle the error
      thisform.Error(laError[1])
    ENDIF
  ELSE
    *-- Force any relations to be updated
    GO (RECNO())
    WAIT WINDOW NOWAIT INFSAVED_LOC
  ENDIF
ENDIF

*- enable new button
oApp.oToolBar.cmdNew.Enabled = .T.
ACTIVATE MENU _msysmenu NOWAIT

RETURN !llError