Trying to save excel file that has data written in it which starts with single quotes

I’m trying to save data that has been written into the excel file that starts with single quote “'”, when I use the activity “Write Data table to excel” it shows that it printed out the result I wanted which is the data starts with single quote plus it had this green mark on the upper left side corner of the cell like the one in the image below:

But after writing the data table and exiting the Use Excel File and Excel Process Scope activities which leads to the file being saved since I ticked the check box of “Saved Changes”. I open the saved excel file and it shows that as if I didn’t print out the single quote and some of the data that starts with zeros are missing the zeros as show in the image below:

How do I save the excel with the single quotes and zeros?

Hello @wdescalsota,

If I understood correctly, when the bot writes the range, the data is in correct format. But if you open the file and save it, the cells that start by 0, the format is changed?

well, the format is on General and after saving, it’s still on general.

You could try after writing, and before opening, do a for each row, and assign this columns as string.

In excel, if you write ‘mytext in a cell, it automatically converts to string, so maybe if the first way doesnt work, try to assign these columns as "’"myvar