Consulting

Results 1 to 2 of 2

Thread: Copying a range from a different workbook

  1. #1

    Smile Copying a range from a different workbook

    Hello

    Is there anyway to copy a range from one workbook to another using the = method

    eg: Workbooks(1).Worksheets(1).Range("A1:A10") = Workbooks(2).Worksheets(1).Range("A1:A10")

    I have tried this and it does not seem to copy anything, and no error comes up.

    I can successfully do it by

    Workbooks(2).Worksheets(1).Range("A1:A10").Copy Workbooks(1).Worksheets(1).Range("A1:A10")

    But I am looking at different methods and the difference in speed that each method takes.

    Thanks

  2. #2
    VBAX Expert CatDaddy's Avatar
    Joined
    Jun 2011
    Posts
    581
    Location
    fastest!!!
    [VBA]
    Workbooks("Destination").Worksheets(1).Range("A1:A10").Value = Workbooks("Source").Worksheets(1).Range("A1:A10").Value
    [/VBA]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •