+ Reply to Thread
Results 1 to 3 of 3

VBA Loop. If true then copy this data into column A

  1. #1
    Registered User
    Join Date
    09-18-2015
    Location
    london
    MS-Off Ver
    2010
    Posts
    18

    VBA Loop. If true then copy this data into column A

    Hi,

    I am trying to loop through my data and if the data matches the Code and then next two columns are blank then look at the next row. If that is the Team then paste the code in column A and the Team in column B.

    HTML Code: 
    However I am struggling

    I have used this kind of loop before when looking for a date but i was able to use the IsDate function so was easier.

    Would appreciate any help.

    Many thanks

  2. #2
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: VBA Loop. If true then copy this data into column A

    Perhaps someting like this will work.

    Please Login or Register  to view this content.
    As Maxrow is not a VBA command as far as I know I've set an arbitrary value of 100 for this since I don't know this value.

    Alf

  3. #3
    Forum Expert Alf's Avatar
    Join Date
    03-13-2004
    Location
    Gothenburg/Mullsjoe, Sweden
    MS-Off Ver
    Excel 2019 and not sure I like it
    Posts
    4,758

    Re: VBA Loop. If true then copy this data into column A

    Thanks for rep

    If this solves you problem don't forget to mark thread "Solved" as pr forum rules.

    Alf

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. loop through range to copy row if data exists in column, then delete the column
    By wpryan in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 08-01-2015, 05:03 PM
  2. [SOLVED] Copy dynamically changing column and Paste using VBA Loop (Loop within Loop)
    By nixon72 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 02-12-2013, 12:46 PM
  3. Loop through sheets copy column move to end of data
    By apunc1 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-30-2013, 11:49 AM
  4. [SOLVED] Copy/Paste Macro Loop For A column of Data
    By brooksbil in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 08-31-2012, 02:31 PM
  5. Copy Paste and Loop till last column with data
    By eirumba in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-08-2011, 07:23 AM
  6. Last Used Column in Loop Data Copy
    By gsurge in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-31-2011, 01:29 PM
  7. Replies: 1
    Last Post: 05-06-2011, 03:08 AM

Tags for this Thread

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