Just asked a powershell question here Finding excel cell reference and I need to add to it.
The overall code I ended up with is as follows.
$filePath = "c:\temp\test.xlsx"
if (test-path $filePath) {
$wb = $xl.Workbooks.Open($filePath)
$ws = $wb.Worksheets.Item("sheet1")
if ([bool]$ws.cells.find("German Baseload")) {write-host $ws.cells.find("German Baseload").address(0, 0, 1, 0)}
}
This returns a cell reference of F25 which is where the string is located, based on this I want to test the cell next to it in cell reference G25, my question is how do I add one column to F25?