How to read cell (NUMBERS) in Excel


#1

Hello! When I try to read a cell in Excel consisted of numbers (for instance 1234), a error appears:

image

The variable is stored as a string.

If instead of numbers I store text, then it works properly.

Thanks!!


#2

Hi @pal1910,

Please check the variable type.

Regards,
hacky_wacky


#3

Hey!
The variable type is “string”. I also tried using “Int” but didn’t work.
What should I use?

Thanks!!


#4

Hi @pal1910,

Please check this out.

It is working fine for me.

Please mark as Solution for my respnse if it solves your problem.

Thanks and Regards,
hacky_wacky


#5

@pal1910

why cant you try like this

Read the excel sheet and store it in a datatable dt by using read range activity.
Then Access the cell value like below

strCellValue=dt(Row Index)(“Column Name”)
or

strCellValue=dt(Row Index)(Column Index)

Regards,
Mahesh