PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
TableSetFocus (Function)
In French: TableDonneFocus
Gives focus to a row found in a Table or Treeview Table control: the control switches to edit for the specified row and column.
Example
// Add a row and switch to edit on "New" (COL_Name column)
let nRow = TableAddLine(TABLE_MaTable, "New", 2)
TableSetFocus(TABLE_MyTable, nRow, COL_Name)
Syntax
<Result> = TableSetFocus(<Table Control> [, <Subscript> [, <Column Name>]])
<Result>: Boolean
  • True if the Table control is switched to edit,
  • False otherwise.
<Table Control>: Control name
Name of Table control to use. This control can correspond to:
  • a Table control.
  • a TreeView Table control.
<Subscript>: Optional integer
Subscript of the row that will take focus.
If this parameter is not specified, the focus is given to the current row. If there is no current row, TableSetFocus has no effect and it returns False.
<Column Name>: Optional character string (with or without quotes)
Name of table column that will take focus.
If this parameter is not specified, the focus is given to the first valid column in the display order.
If there is no valid column (or if the column name does not correspond to a column in the Table control), TableSetFocus has no effect and it returns False.
Remarks
  • If the Table control does not have focus, TableSetFocus gives focus to the control.
  • If the Table control is grayed or inactive, TableSetFocus has no effect and it returns False.
  • The processes for entering or exiting controls, rows and columns are NOT run.
  • If the Table control already is in edit, the number of the row or column in edit is modified.
  • The rows displayed in the Table control may be moved in order for the row with new focus to be visible.
Components
WINDEVReports and Queries wd230obj.dll
Android wd230android.jar
Minimum required version
  • Version 22
This page is also available for…
Comments
Click [Add] to post a comment