Hi,
I am trying to copy data from one sheet to other sheet. For some column its working fine but when I am trying to copy date column its giving garbage value.
One more issue is every time when I am running the macro data is copying to next row of sheet2.But I want to overwrite the sheet2 data.It will start copy from 2nd row.
Why not some thing like that your code which is in attached file?
[vba]
Sub CopyPaste()
With Sheets("Sheet1")
.Range("A1:A65536").Copy
End With
Sheets("Sheet2").[A1:A65536].PasteSpecial Paste:=xlValues
With Sheets("Sheet1")
.Range("b1:b65536").Copy
End With
Sheets("Sheet2").[b1:b65536].PasteSpecial Paste:=xlValues
on error resume next
Sheets("Sheet2").select
Columns("B:B").Select
Application.CutCopyMode = False
Selection.NumberFormat = "m/d/yyyy"
End Sub
[/vba]
Please record a macro that wil based on your string values it will solve your issue and for copy purpose you can use the same code which is on below post.