The range A0 does not exist

Hi, my robot searches for the first empty row using Find First/Last Data Row activity and enters the text using sentences:
Excel3.Sheet(“Sheet1”).Cell(“A” & firstemptyrow.tostring())
But if excel is empty or there are only headers then an error appears: The range A0 does not exist.

Do you have any idea how to make it work?

looks like firstemptyrow is not set properly, so the default value (0) is taken.
Minimum range is 1, so first cell is A1

Hey @sullivanne try this

Excel.Sheet(“Sheet1”).Cell(“A” & (OutLastRowIndex + 1).ToString())

so this will check the last row data and update into the next cell
and if you want to run that in the loop check the auto increament option

cheers