Sub testsavecopyfile()
Dim source As Range
Dim target As Range
With Workbooks("CopyData.xlsm").Sheets(1)
Set source = .Range("a2", .Range("h" & .Rows.Count).End(xlUp))
End With
With Workbooks("PasteData.xlsx").Sheets(1)
Set target = .Range("a2")
End With
source.Copy
target.PasteSpecial xlPasteValues
Application.CutCopyMode = fasle
End Sub
แต่คิดว่ายังไม่ใช่ รบกวนหน่อยนะค่ะ
Tag : .NET, Ms Access, Excel (Excel.Application), VB.NET