CurrentRow DataWindow expression function
Description
Reports the number of the current row (the row with focus).
Syntax
1 |
<span>CurrentRow</span> ( <span></span>) |
Return Values
Long. Returns the number of the row if it succeeds and 0 if
no row is current.
The current row is not always a row displayed on the screen.
For example, if the cursor is on row 7 column 2 and the user uses
the scroll bar to scroll to row 50, the current row remains row
7 unless the user clicks row 50.
Examples
This expression in a computed field returns the number
of the current row:
1 |
<span>CurrentRow</span>() |
This expression for a computed control displays an
arrow bitmap as an indicator for the row with focus and displays
no bitmap for rows not having focus. As the user moves from row
to row, an arrow marks where the user is:
1 |
Bitmap(If(<span>CurrentRow</span>() = GetRow(),"arrow.bmp","")) |
Alternatively, this expression for the Visible property
of an arrow picture control makes the arrow bitmap visible for the
row with focus and invisible for rows not having focus. As the user
moves from row to row, an arrow marks where the user is:
1 |
If(<span>CurrentRow</span>() = GetRow(), 1, 0) |