Forum Discussion

Jamesupp's avatar
Jamesupp
Copper Contributor
Sep 27, 2021
Solved

Automated copy and paste

Hi there, I have data from a cell that I need to copy and paste the values to a different cell so that I can turn that cell into a table to extract from. Is there a way to automatically copy and past...
  • NikolinoDE's avatar
    Sep 27, 2021

    Jamesupp 

    Simplified with formula:

    =IF(B2="","",A1)

     

    With VBA:

    Sub Copy_Paste()
        On Error Resume Next
        Dim xRg As Range
        Set xRg = Application.Selection
        Range("A1:A10 ").Copy Range("D1:D10")
        xRg.Select
    End Sub

     

    Hope I could help you with these information / links.

     

    NikolinoDE

    I know I don't know anything (Socrates)

Resources