Copy and paste data from one excel to other excel with the same cell color and format

I have two excel files… File A and File B. From file A I need to read a sheet and paste data into File B with the same cell colors and format. I have used read and write range but the colors and format are not getting. If I use preserve format some data format are changed.

If I try manually copy and paste the data from file A to file B its as expected format…

Please help to solve this…

use macros or vb script you can easily copy paste exact

or else use copy/paste range activity

Will you please advise me how to do that…I dont know about VB script and macros

Sub Macro2()

’ Macro2 Macro

End Sub

Hello @KKsekar.
Did you try with:
DataTable.Clone Method(): ??
It clones all the datatable schemas and constraints (structure)

It’s something like that.
DataTable newTable = originalTable.Clone()

Hello @KKsekar

Can you please share 2 excel files and explain which values needs to copy to another file.
Based on that we can try out some methods.

This is my excel file A there are lot more rows and columns…file B is empty fresh excel sheet

No I didnt tried this…plz advise

@KKsekar is it allowed to use custom activities? If yes, can you try the below package and the Copy to file activity.

1 Like

Hi @KKsekar ,

Have you tried the Copy/Paste Range Activity ?

Tried i didnt worked

@KKsekar , Have you Checked with Copy Sheet Activity, Maybe it suits your case more.

Hello! I use StudioX. Could you please provide how to copy a tab from one workbook to the other un StudioX?

1 Like