I am using a template in excel to proceed with the automation. The bots get the template, read range and paste it to the output excel file (for each transaction a new sheet is created in the output excel file). The issue is that I use write range to write the template in the output, but when I write the datatable in the output excel file, the template dissappear. The datatable is written as it would be in a new sheet.
For example, the template contains colors. But when I write the datatable, the colors dissappear.
I cannot use excel application scope because the process is based in background mode.
I might be wrong but, aren’t DataTables formatted as plain text?
My personal solution would be instead of having the writeline to attempt writting the template, why not having a generic template file and create a a copy whenever you need to use it, in that way you will preserve the formatting.
I believe your template is overwritten by your data table. Can you try writing the date table on any empty rows below your template and see if you can retain the colors you mentioned missing.