Two OCR String to Int

Hello,

I got with the OCR a string variable containign “1,600.00” and another one with “1,200.00” I would need to send an email with the addition of both variables which should be “2,800.00” I have tried so many conversions but they only give the result as “280000”

Please send me some help

Hello @Francisco_Herrera,
Can i see what conversion you’re using?

I´ve tried Cint(variable) and Convert.ToInt32(variable.Replace(".","").Replace(",","").Trim

@Francisco_Herrera
As it contains decimals you can directly convert it to a double value without replacing anythng!

just do Convert.ToDouble(str1)+Convert.ToDouble(str2) and assign it to a double type variable! :slight_smile:

1 Like

@Francisco_Herrera Did it help?

It appears that I don´t have the level to use Double, :frowning: how can I solve it?

What do you mean by do don’t have the level?

Sorry, I was wrong, it actually worked thanks (:smile:

1 Like