Results 1 to 6 of 6

Help needed with VBA to iterate through a worksheet

Threaded View

  1. #1
    Registered User
    Join Date
    01-25-2023
    Location
    UK
    MS-Off Ver
    Windows 10 Enterprise
    Posts
    5

    Question Help needed with VBA to iterate through a worksheet

    I am trying to make a macro that will check an export and copy certain cells if specific requirements are met.

    In a nutshell, I want to iterate through the cells in column P. If Px=0, then go on to cell P(x+1) and check the value. When Px=1 then I need to iterate through column N to find N(x+y)=1. Once this condition is met I want to copy the range Ax:I(x+y) to another sheet within the same workbook.

    After copying I want the iteration to go on, checking the conditions every time and copying when necessary, until it reaches the end. Every time it copies to the next sheet, I would like the copy to be underneath the previous copy.

    My question is, can this be done with VBA? I haven't touched VBA in decades, and so am quite rusty. I'm not asking that anyone solve this, but rather that they point me in the right direction. Which VBA functions should I considering using, etc.?
    Attached Files Attached Files

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. new to vba-looking to iterate
    By student2110 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 10-30-2019, 02:03 PM
  2. Iterate through worksheet and add to listview
    By DPashley in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 06-30-2016, 10:53 AM
  3. [SOLVED] VBA code needed to iterate to common solution
    By hassanm in forum Excel Programming / VBA / Macros
    Replies: 17
    Last Post: 07-09-2015, 09:28 AM
  4. iterate
    By Gaurav_92 in forum Excel General
    Replies: 1
    Last Post: 06-03-2014, 01:42 AM
  5. Macro help needed to collate data from one worksheet into a second worksheet
    By Pearl18 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-01-2009, 07:20 AM
  6. need to iterate, or something...
    By jacquesmckenna in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 02-28-2008, 11:34 AM
  7. [SOLVED] Can't iterate thru a row with For
    By peter in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-07-2005, 01:06 AM

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1