addnew Method
Class: orderentry
Expand/Collapse source code of procedure addnew Source Code
IF ALIAS() <> "ORDERS"
  SELECT orders
ENDIF

thisform.lAllowEdits = .T.
thisform.lAllowDelete = .T.
*-- Refresh the toolbar
IF TYPE("oApp") == "O"
  oApp.oToolbar.Refresh()
ENDIF
IF tsBaseForm::AddNew()
  *-- Add a blank record to the grid so the user can tab into it
  INSERT INTO order_line_items ;
    (order_id) ;
    VALUES ;
    (orders.order_id)
  thisform.grdLineItems.Refresh()
  thisform.cboCustomer_ID.SetFocus()
ENDIF