PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

New WINDEV 23 feature!
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
SpreadsheetReplace (Function)
In French: TableurRemplace
Finds and replaces a value in a Spreadsheet control.
Note: This operation can be canceled by the user by pressing CTRL + Z.
Example
// Replace VAT by Value A.T
nRepl is int = SpreadsheetReplace(PSHEET_MySpreadsheet, "VAT" , "Value A.T.")
IF nRepl = 0 THEN
Info("Not found")
ELSE
Info("[%nRepl%] elements have been replaced.")
END
Syntax
<Result> = SpreadsheetReplace(<Spreadsheet Control> , <Sought Value> , <ReplaceBy> [, <Cell> [, <Options>]])
<Result>: Integer
  • Number of replacements done.
  • 0 if no replacement was performed.
<Spreadsheet Control>: Control name
Name of Spreadsheet control to use.
<Sought Value>: Real or character string
Value to find in the Spreadsheet control in order to be replaced.
<ReplaceBy>: Real or character string
New value that will replace the sought value.
<Cell>: Optional character string
Name of cell to modify.
  • If this parameter is specified, only the corresponding values in this cell will be replaced.
  • If this parameter is not specified, all the corresponding values (in the current worksheet or in all worksheets, according to the <Options> parameters) will be modified.
<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 while 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
Components
WINDEVReports and Queries wd230obj.dll
Minimum required version
  • Version 23
This page is also available for…
Comments
Click [Add] to post a comment