Excel VBA Macro: Pull Specific Columns from One Sheet to Another (Dynamically)

แชร์
ฝัง
  • เผยแพร่เมื่อ 3 พ.ย. 2024

ความคิดเห็น • 48

  • @jasonjohnston5256
    @jasonjohnston5256 9 หลายเดือนก่อน

    You completely blew my mind! This is outstanding. Thank you so much!!

  • @Jojosmith342
    @Jojosmith342 ปีที่แล้ว

    Perfect. I follo'w your instruction carefully. Trying to type in from screen first & use your written code as refference. You are GENIUS. Thank you so much Greg for all your hard work, time to educate us. Your tutorials are always valuable & absolutely thumbs up both hands 👌👏

  • @patriciapetri4792
    @patriciapetri4792 11 หลายเดือนก่อน

    I love it!! thank you for teaching us. you made it so simple and easy to understand and follow... great job!!

  • @Adam_K_W
    @Adam_K_W 8 หลายเดือนก่อน

    Nicely done. Don't forget to set your objects to nothing before you exit the sub.

  • @josephraji296
    @josephraji296 ปีที่แล้ว

    Very well explained and it is working very much fine for me after researching so much i found nowhere except yours so i subscribed to your channel.

    • @greggowaffles
      @greggowaffles  ปีที่แล้ว

      I really appreciate that! Thank you for the feedback

  • @jiayilow5657
    @jiayilow5657 26 วันที่ผ่านมา

    Hi, how should i modify it to exclude copying of selected rows (assuming one of the cells in the row-to-be-skipped contains data that i can define as unwanted?)

  • @arditiljazi6959
    @arditiljazi6959 ปีที่แล้ว

    thank you for showing this sample. is there a way of tweaking it to show it can copy and paste the specific columns to another worksheet?

  • @drewgossage8842
    @drewgossage8842 2 ปีที่แล้ว +1

    Really cool, straight to the point, great tutorial!

    • @greggowaffles
      @greggowaffles  2 ปีที่แล้ว

      Appreciate the feedback 😊

    • @richardmoore7955
      @richardmoore7955 ปีที่แล้ว

      @@greggowaffles Dim i As Integer
      Dim j As Integer
      Why are these letters used as the integer

  • @airman-xx9vg
    @airman-xx9vg ปีที่แล้ว

    finally, got it!!! thanks. code works great 👍👍👍👍

    • @greggowaffles
      @greggowaffles  ปีที่แล้ว

      Glad to hear that!! Thanks for watching!! 💪💪

  • @johnnastasi9143
    @johnnastasi9143 2 ปีที่แล้ว

    Excellent, Can this macro be modified to always pull x number of columns and place them in a sheet sequentially Sheet-001, sheet-002, etc?

  • @cathy___m
    @cathy___m ปีที่แล้ว

    This is insightful. Thank you.
    But can you please do it with more than 2 sheets? I am struggling with consolidating my 2nd sheet into the master sheet. I managed to do it for the 1st sheet using the method. I know we have to use LastRow to copy into the lastrow of the master sheet but I still can’t seem to get it right.

  • @niakubheka9099
    @niakubheka9099 ปีที่แล้ว

    Hi Gregg. Thank you for the vid, it was very helpful. I used the code for my sheets and it worked very well. Can you please assist me with how I can put additional data from a different sheet underneath the already transferred data (on the next empty line) of the worksheet. I need to consolidate from different sheets. Your assistance will be greatly appreciated.

  • @abrahamruiz7034
    @abrahamruiz7034 ปีที่แล้ว

    Do you happen to have a way to pull columns into different sheets at once?

  • @Jojosmith342
    @Jojosmith342 ปีที่แล้ว

    Hi Greg, I have a large spreadsheet with >50,000 records. Problem I am facing is there is a heading row (without data) between these records. To consolidate the db I need to remove these heading rows (contain no data, simply heading) on spreadsheets. It is very challenging as it is a huge database. Could you please kindly help to make a tutorial how to resolve this issue? Thanks a lot Greg

  • @468SQLTrain
    @468SQLTrain ปีที่แล้ว

    Hi there, how do you deal with copying over a column that contains dates? Thanks

  • @airman-xx9vg
    @airman-xx9vg ปีที่แล้ว

    don't know what's wrong but I always end up on copying and pasting just the first two columns from raw data on sheet 2 after running the codes, what could be the problem?

  • @andytawandamahdania7943
    @andytawandamahdania7943 ปีที่แล้ว

    It's a great tutorial 👍
    But can you tell us how to pull specific column with some applied filter? Thx

  • @davidlinton4127
    @davidlinton4127 7 หลายเดือนก่อน

    Could you use an advanced filter instead?

  • @vinaypharande2637
    @vinaypharande2637 ปีที่แล้ว

    Hi, while running this VBA Macros. I'm receiving fix Run-time error '6' Overflow. How should I fix it. Please guide.

  • @h3rw3i
    @h3rw3i ปีที่แล้ว

    Hi I got an error on this line " If ws2.Cells(1, i) = ws1.Cells(1, j).Text Then" - Run-time error '1004': Application-defined or object-defined error. How do i fix? Thanks in advance.

  • @zingfam7616
    @zingfam7616 ปีที่แล้ว

    Hi, I followed your code but somehow the code is only copy and paste one column. Any idea why ? I want to copy only 8 columns.

  • @ladyteamer9331
    @ladyteamer9331 2 ปีที่แล้ว

    can this be modified to pull column names that are not an exact match?

  • @Andre-ec4xw
    @Andre-ec4xw 10 หลายเดือนก่อน

    Hi, I was using this code and it worked perfectly, but now I get an error code (400) can you help please

  • @avinashbiju5329
    @avinashbiju5329 11 หลายเดือนก่อน

    What to do if the value to be copied is a number and text, how would that be assigned?

  • @Sharath_hp
    @Sharath_hp 11 หลายเดือนก่อน

    One specific column values are not getting copied. What do do?

  • @gospelmoto2833
    @gospelmoto2833 ปีที่แล้ว

    superb! got a new sub here. Thanks!

  • @v12onK
    @v12onK 2 ปีที่แล้ว

    What if I want to pull a specific date or date range?

  • @airman-xx9vg
    @airman-xx9vg ปีที่แล้ว +1

    it would be a big help if you'll share the excel file with that VBA code. 😅😅😅

  • @shizmeeamir5307
    @shizmeeamir5307 2 ปีที่แล้ว

    Row Count say shows an error " Runtime Error 6 / Overflow " .. What does this mean ??

  • @ahmetokur8224
    @ahmetokur8224 2 ปีที่แล้ว

    Teşekkür ediyorum.

  • @MohAboAbdo
    @MohAboAbdo ปีที่แล้ว

    Thank you so much

  • @serginhov2
    @serginhov2 ปีที่แล้ว

    Hello, I'm getting error to use this macro, could you please help. Application-defined or object-defined error . I'm trying to put from sheet to another. Not workbook

  • @alializadeh8195
    @alializadeh8195 2 ปีที่แล้ว

    Thanx

  • @sarahanyayahan240
    @sarahanyayahan240 9 หลายเดือนก่อน

    This doesnt work for me. I dont know the prob

  • @richardmoore7955
    @richardmoore7955 ปีที่แล้ว

    Dim i As Integer
    Dim j As Integer
    Why are these letters used as the integer

    • @greggowaffles
      @greggowaffles  ปีที่แล้ว

      Just a preference. You can use whatever letter/word you want

  • @me1234540
    @me1234540 ปีที่แล้ว +1

    Man you can’t even imagine how I hated this video… sorry but who in the hell that doesn’t have any clue about formulas is going to be able to write all the formulas you wrote?
    I thought the point of the video was just to apply a direct formula to pull the columns from one WS to another. Not helpful at all!
    Tutorials are meant to be for people who DO NOT know anything about it.

    • @greggowaffles
      @greggowaffles  ปีที่แล้ว +1

      Thank you for watching the video and sharing your feedback. I aim to be as descriptive as possible with the video titles so that people know exactly what to expect in the videos. I have beginner tutorials on my channel if you want to check them out, and if there’s a specific example you have I can try to help you out.