Hi, please help to see wahat's the code as below which wrong as color RED, the intents is want to get data base on the acitive sheet to paste base on Rrows count from cloumn "B"
Sub testing()
Dim home As Worksheet
Dim Filename As String
Dim Wb As Workbook
With Application.FileDialog(msoFileDialogOpen)
.AllowMultiSelect = False
If .Show = -1 Then
Filename = .SelectedItems(1)
Set home = ActiveWorkbook.ActiveSheet
Range("B1").Select
Set Wb = Workbooks.Open(Filename)
Wb.Worksheets("MAN_SUM").Range("K6:K7").Copy
home("Sheet1").Cells(Rows.Count, "B").End(x1up).Offset(1).Paste Wb.Close (False)
End If
End With
End Sub
your help I highly appreciate
Sub testing()
Dim home As Worksheet
Dim Filename As String
Dim Wb As Workbook
With Application.FileDialog(msoFileDialogOpen)
.AllowMultiSelect = False
If .Show = -1 Then
Filename = .SelectedItems(1)
Set home = ActiveWorkbook.ActiveSheet
Range("B1").Select
Set Wb = Workbooks.Open(Filename)
Wb.Worksheets("MAN_SUM").Range("K6:K7").Copy
home("Sheet1").Cells(Rows.Count, "B").End(x1up).Offset(1).Paste Wb.Close (False)
End If
End With
End Sub
your help I highly appreciate