+ Reply to Thread
Results 1 to 5 of 5

VBA to paste data in next availble blank row within a range.

Hybrid View

Zimmerman VBA to paste data in next... 03-16-2016, 11:11 AM
dflak Re: VBA to paste data in next... 03-16-2016, 03:34 PM
Mschaub Re: VBA to paste data in next... 03-16-2016, 03:50 PM
Zimmerman Re: VBA to paste data in next... 03-17-2016, 06:57 AM
Mschaub Re: VBA to paste data in next... 03-17-2016, 05:34 PM
  1. #1
    Forum Contributor
    Join Date
    07-01-2010
    Location
    Niles, Michigan
    MS-Off Ver
    Excel 2010
    Posts
    137

    VBA to paste data in next availble blank row within a range.

    How could I find the next blank row and paste data in it in from a range of F4:M12. So if I enter data in cell J16 I am performing a vlookup and I'd like the return value to go to the next blank cell in range J4:J12. So if cells J4:J9 have data in it the result of the vlookup would go in cell J9.

    Thanks in advance
    Excel 2010

  2. #2
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,957

    Re: VBA to paste data in next availble blank row within a range.

    I'm having a difficult time understanding the requirement F4:M12 overlaps J4:J12. What are you looking up? A sample spreadsheet would help a lot.
    One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.

    A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.

  3. #3
    Registered User
    Join Date
    03-16-2016
    Location
    Syracysem =New York
    MS-Off Ver
    2007
    Posts
    8

    Re: VBA to paste data in next availble blank row within a range.

    Are you wanting to do this with just a formula or in VBA?

    Can you also give a small example of the data set? Just enough so we will know what you are trying to accomplish?

  4. #4
    Forum Contributor
    Join Date
    07-01-2010
    Location
    Niles, Michigan
    MS-Off Ver
    Excel 2010
    Posts
    137

    Re: VBA to paste data in next availble blank row within a range.

    This is just a sheet that is used fro baseball drafting. In cells F4:M12 is data validation lists of all the kids who are 11 years old. The columns are the actual teams. So there are a total of 9 teams. In cells F13:M19 are data validation drop down boxes as well but these are of 12 year olds. So what I'm trying to accomplish is if I choose a player that is 12 years old (in cell J16) and they have a younger brother who is 11 the vlookup kicks in and will return the 11 year old brothers name in the next available blank cell (in this scenario in cell J9 since cells J4:J8 have a name in it already) in that same row. Attached is a sample file
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    03-16-2016
    Location
    Syracysem =New York
    MS-Off Ver
    2007
    Posts
    8

    Re: VBA to paste data in next availble blank row within a range.

    So I am assuming you have a spreadsheet somewhere that has the sibling information listed since you refer to the vlookup kicking in. Is there a column that indicates the siblings are related? You can't just go on last name as there are often siblings with different last names. I am also assuming that if you select Billy for the Yankees and Jamie is added to the team, those 2 players should not be available for drafting on another team. What should happen if all the spots for an age group are filled when a sibling is chosen in a slot of another age. For example, lets say Billy is chosen in the 12 year old section, Jamie is his sibling but there are no more open 11 year old slots available. What should happen? What should happen if you have 2 siblings the same age? Should they go to the same team?

    How are you envisioning this will work, with VBA code or with just formulas?

    Sincerely,

    Marty

+ 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. [SOLVED] copy only non-blank cells in range and paste to new range.
    By scrabtree23 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-29-2015, 08:10 PM
  2. [SOLVED] Macro to copy and paste new data into the next blank cell WITHIN a range
    By MattRNR in forum Excel Programming / VBA / Macros
    Replies: 32
    Last Post: 10-22-2015, 12:45 AM
  3. Find Date Range data's and paste the next sheet blank row.
    By rskfriends in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-09-2013, 03:41 AM
  4. Paste range at first blank row
    By mumsys in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-19-2013, 04:36 AM
  5. Replies: 4
    Last Post: 03-17-2013, 05:58 AM
  6. Enter text value into next availble cell in range if user selects correct answer
    By jerbaldw in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-18-2012, 10:24 AM
  7. [SOLVED] Object not availble onthis machine.
    By Kjeldc in forum Excel General
    Replies: 0
    Last Post: 08-08-2005, 02:07 PM

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