How to solve error: "Read range : Not a legal OleAut date." in excel?

Hello There,

I am trying to read the excel sheet which basically is reading date column and comparing if it is a future date.
But I am getting error as “Read range : Not a legal OleAut date.”

how to solve this problem?

Kind Regards,

1 Like

I was having the same issue and it was due to for some weird reason the “read range” activity couldn’t actually get the cell or it would get it in the wrong format instead of just the value of the cell.

What worked for me is putting the read range activity in a “Excel Application Scope” which effectively quickly opens excels, does what ever is in it’s scope and closes excel. After implementing that it was able to pick up on the values in excel.

Another option would be to try and print the value of the cell before you do anything to it to make sure you’re returning a correct value.

Thank you for your response :slight_smile:
I have found a solution from someone…
The problem was with excel sheet.
one row that had type "Custom " and the column type was “General” hence they were conflicting.

So lesson learnt is to check if there mismatch in cell types.