View Single Post
 
Old 04-22-2018, 10:58 AM
Logit Logit is offline Windows 10 Office 2007
Expert
 
Join Date: Jan 2017
Posts: 533
Logit is a jewel in the roughLogit is a jewel in the roughLogit is a jewel in the rough
Default

Paste in a routine module :

Code:
Option Explicit

Sub Copy_Columns()
Dim shA As Worksheet, shB As Worksheet, LastRow As Long
    
    Set shA = Sheet1
    Set shB = Sheet2
    
    LastRow = shA.Cells.Find("*", , xlValues, , 1, 2).Row
    
    Application.ScreenUpdating = False
    
    shA.Activate
          
    Application.CutCopyMode = False
    
    shA.Range("E5:E" & LastRow).Copy shB.Range("A3")
    shA.Range("I5:I" & LastRow).Copy shB.Range("D3")
       
    Application.ScreenUpdating = True
    shB.Activate
End Sub

Sub Reset()
Dim shA As Worksheet, shB As Worksheet, LastRow As Long

    Set shA = Sheet1
    Set shB = Sheet2
    LastRow = shB.Cells.Find("*", , xlValues, , 1, 2).Row
    
    shB.Range("A3:D" & LastRow).Clear
    shA.Activate

End Sub
Attached Files
File Type: xlsm Inventory.xlsm (21.3 KB, 17 views)
Reply With Quote