deleteRow

deleteRow(n): DeleteRow deletes the row from the DataWindoss primary buffer.

deleteAllRow(): Delete all rows

If the DataWindow is not updatable, all storage associated with the row is cleared. If the DataWindow is updatable, DeleteRow moves the row to the DataWindows delete buffer; PowerBuilder uses the values in the delete buffer to build the SQL DELETE statement.

 

The row is not deleted from the database table until the application calls the Update method. After the Update method has updated the database and the update flags are reset, the storage associated with the row is cleared.

 

Example:

dw_1.deleteRow(1);

 

Delete current row: use 0

dw_1.deleteRow(0);

 

Delete all rows:

dw_1.deleteAllRows()

 

Events

Follow events called (x=1-7):

dw_x_delete()
dw_x_deleted()
dw_x_sortchanged()

if event dw_x_delete() return -1, the process stopped with return value "false"