Gets the unique row identifier of a row in a DataWindow control or DataStore object from the row number associated with that row.
long dwcontrol.GetRowIdFromRow (long rownumber {, DWBuffer buffer } )
Argument |
Description |
---|---|
dwcontrol |
A reference to a DataWindow control, DataStore, or the child DataWindow. |
rownumber |
A number specifying the row number for which you want the associated row identifier. |
buffer (optional) |
A value of the dwBuffer enumerated datatype identifying the DataWindow buffer that contains the row. For a list of valid values, see DWBuffer. |
Returns the row identifier in buffer. Returns 0 if the row identifier is not in the current buffer and -1 if an error occurs. If any argument value is NULL, the method returns NULL.
The row identifier value is not the same as the row number value used in many DataWindow and DataStore function calls and should not be used for the row number value. Instead you should first convert the unique row identifier into a row number by calling GetRowFromRowId.
This example retrieves the current row’s unique identifier:
long ll_rowid
ll_rowid = dw_emp.GetRowIDFromRow(dw_emp.GetRow())
Copyright © 2004. Sybase Inc. All rights reserved. |
![]() |