Need delete an entire row of an excel file (.CSV), when value of column A or value of Column C is null.
This is what i have so far :
$ab = New-Object -comobject excel.application
$bc = $ab.Workbooks.Open("C:\Users\abc\Desktop\New.csv")
$cd = $bc.Worksheets.Item(1)
$used = $cd.usedRange
$lastCellCnt = $used.SpecialCells($xlCellTypeLastCell)
$row = $lastCell.row
From the above code i get the number of records, was thinking of applying a loop to delete the records. For example :
if A2 == null or C2 == null then delete entire row