INDEX_OF_IGNORE_CASE
Description
Returns the zero-based index of the first occurrence of substring within string(case-insensitive). Optionally starts searching from index_optional. Returns -1 if not found.
Syntax
INDEX_OF_IGNORE_CASE(string, substring, index_optional) -> Integer
Parameters
| Parameter | Data Type | Required | Description |
|---|---|---|---|
| string | String | Yes | The string to search within. |
| substring | String | Yes | The substring to locate. |
| index_optional | Integer | No | The starting index for the search (zero-based). Defaults to 0. |
Examples
INDEX_OF_IGNORE_CASE("Sales_Report.XLSX", ".xlsx")
-- Returns 12.INDEX_OF_IGNORE_CASE("Voltage=220V", "Temperature=")
-- Returns -1.INDEX_OF_IGNORE_CASE("Report.Q1.Final.PDF", ".pdf", 10)
-- Returns 15. Finds the first occurrence of ".pdf" starting from index 10 (case-insensitive).