- API -
cellSearchResult = reaper.AZ_Excel_SearchCellsInWorksheet(excelDocument, searchStr, range, isRegex)
- API Detail-
▼Input value
excelDocument(ExcelDocument) : Excel document
searchStr(string) : Search string
range(string) : Search range
・Single row and column specification
・Row 1: Row 2, Column 1: Column 2 Multiple specifications (optional, default: all range)
Row 1: Row 2, Column 1: Column 2 Multiple specifications (Optional, default: all range)
isRegex(boolean): Regular expression search (optional, default: FALSE)
▼Output value
"cellSearchResult(ExcelSheetInfoArray) : Worksheet array
-Name : Worksheet name
-Worksheet : Worksheet
-Cells: Cells (map)
- key : line number
- value : column (map)
- key : column number
- value : cell value
- SCRIPT -
dofile(reaper.AZ_GetLuaInitPath())
require("reaper_AZSTOKE_GOLD")
function showObject(object, depth)
local obj = object
if depth == nil then depth = 0 end
if(type(obj) == "table") then
Msg("")
for k, v in pairs(obj) do
for i = 1, depth, 1 do reaper.ShowConsoleMsg(" ") end
reaper.ShowConsoleMsg(tostring(k) .. " : ")
showObject(v, depth + 4)
end
else
Msg(obj)
end
end
doc = reaper.AZ_Excel_OpenFile("D:\\rigdocks\\01_APIDock\\test.xlsx")
sheetList = reaper.AZ_Excel_SearchCellsInAllWorksheets(doc, "01")
Msg("result : " .. tostring(reaper.AZ_GetErrorCode()))
showObject(sheetList)
reaper.AZ_Excel_CloseFile(doc)
Excel
AZ_Excel_SearchCellsInAllWorksheets
Supported versions:
1.1.0
onwards
Row search in all sheets
