Help / WLanguage / WLanguage functions / Controls, pages and windows / Spreadsheet functions
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WindowsLinuxPHPWEBDEV - Browser code
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Stored procedures
Seeks a value in the cells of a Spreadsheet control found in a window.
sCell is string = PSHEET_NoName1.Seek("%CUSTOMERNAME%")
// Processes the result of the search
IF sCell <> "" THEN
 // Replaces %CUSTOMERNAME% by Doe
 PSHEET_NoName1[sCell] = "Doe"
// Browse all cells with "VAT"
sCell is string = PSHEET_NoName1.Seek("%VAT%")
WHILE  sCell <> ""
// Replaces VAT by PSHEET_NoName1[sCell] = 20.6
// Next cell
sCell = PSHEET_NoName1.Seek("VAT", sCell)
<Result> = <Spreadsheet control>.Seek(<Sought value> [, <Start> [, <Options>]])
<Result>: Character string
  • Name of cell found ("A1" for example). If several cells are found, <Result> contains the name of first cell found.
  • "" (empty string) if no cell is found.
<Spreadsheet control>: Control name
Name of the Spreadsheet control to be used.
<Sought value>: Type of sought value
Value to find in the cells of Spreadsheet control. This value can correspond to a number or to a character string.
<Start>: Optional character string
Name of the from which the search will be performed. This cell is excluded from the research.
Remark: this parameter is used to browse all cells containing a value.
If this parameter is not specified or is an empty string (""), the search starts at cell "A1".
<Options>: Optional Integer constant
Search options:
psheetSearchWithCaseSearch while taking the case into account.
psheetSearchContain"Contains" search.
psheetSearchInFormulaSearch in the formulas only.
psheetSearchExact"Exact" search.
psheetSearchCurrentWorksheetSearch in the current worksheet.
psheetSearchNoCaseSearch ignoring the case.
psheetSearchAnyWorksheetSearch in all worksheets of workbook.

By default, the search is performed according to the following combination of constants: psheetSearchWithCase + psheetSearchCurrentWorksheet + psheetSearchExact
  • The search is performed in the following order: A1, B1, C1, ..., A2, B2, C2, ...
  • This function can only be used on a Spreadsheet control found in a window.
Component: wd290obj.dll
Minimum version required
  • Version 23
This page is also available for…
Click [Add] to post a comment

Last update: 06/21/2023

Send a report | Local help