Excel format problem

I’m extracting the data from analytics page(basically numbers), when i fetch it and write it to excel, it gets written in “String” format due to which i’m not able to do calculation. I tried converting string to double. The calculation goes fine but “coma” disappears. I just want to know how to write the fetched string as numbers while writing to excel.