+ Reply to Thread
Results 1 to 6 of 6

Populate column with non-blank cells from another column

  1. #1
    Forum Contributor
    Join Date
    07-17-2013
    Location
    Birmingham, England
    MS-Off Ver
    Excel for O365
    Posts
    197

    Populate column with non-blank cells from another column

    Hi all,

    Need some help with a formula I've been trying to work out...

    I want to populate in a new sheet the contents of column E in the sheet named 'Surveys', where the adjacent column S is not blank.

    I thought this formula would do it but it seems to find the first non-blank in S, list the adjacent cell in column E and then repeat this one when dragging down.

    =IFERROR(INDEX(Surveys!$E$7350:$E$8080),SMALL(IF(Surveys!$S$7350:$S$8080)<>"N",ROW($W$7350:$W$8080)-ROW($W$7350)+1,""),ROW($W$7350:$W$8080)-ROW($W$7350)+1)),"")

    Any help greatly appreciated.

    Jason

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,763

    Re: Populate column with non-blank cells from another column

    If you are prepared to use a helper column in your first sheet, you could use much simpler formulae which are not array-entered. For example, you could use this in Z7350:

    =IF(S7350<>"",MAX(Z$7349:Z7349)+1,"-")

    and copy down. Then in your second sheet you could use this in A2:

    =IFERROR(INDEX(Surveys!E:E,MATCH(ROWS($1:1),Surveys!Z:Z,0)),"")

    although your test seems to be for <>"N" rather than <>"" in the first formula.

    Hope this helps.

    Pete

  3. #3
    Forum Contributor
    Join Date
    07-17-2013
    Location
    Birmingham, England
    MS-Off Ver
    Excel for O365
    Posts
    197

    Re: Populate column with non-blank cells from another column

    Hi Pete, thanks for the response.

    It says <> "N" as I changed it to see if that would work as oppposed to <>"". No luck either way.

    Unfortunately I can't edit the Surveys sheet as this is a template document that has been in operation for 5 months. This sheet gets moved into a report template that then looks up the necessary information.

  4. #4
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,763

    Re: Populate column with non-blank cells from another column

    Well, put the helper column in your second sheet in A2:

    =IF(Surveys!S7350<>"",MAX(A$1:A1)+1,"-")

    Then you can have this formula in B2:

    =IFERROR(INDEX(Surveys!E:E,MATCH(ROWS($1:1),A:A,0)+7349),"")

    to extract the data from column E of the Surveys sheet. Copy both down as far as needed.

    You can hide column A if you wish to.

    Hope this helps.

    Pete

  5. #5
    Forum Contributor
    Join Date
    07-17-2013
    Location
    Birmingham, England
    MS-Off Ver
    Excel for O365
    Posts
    197

    Re: Populate column with non-blank cells from another column

    Just tried that method and works brilliantly, thanks a lot Pete. New trick to add to the arsenal.

    Jason

  6. #6
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,763

    Re: Populate column with non-blank cells from another column

    You're welcome - thanks for feeding back.

    Pete

+ 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. Populate column with non-blank cells from another column
    By jwillis07 in forum Excel General
    Replies: 7
    Last Post: 09-04-2014, 09:19 AM
  2. [SOLVED] Populate row if cell in column A is blank.
    By Macfool in forum Excel General
    Replies: 2
    Last Post: 02-26-2014, 10:29 AM
  3. Populate Blank Cells in Column F with formula
    By LarryJ79 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-23-2013, 12:59 PM
  4. [SOLVED] Auto populate cells in one column based if cells in next column are populated
    By diablo86 in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 07-22-2013, 06:29 AM
  5. Replies: 2
    Last Post: 10-04-2012, 03:19 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