+ Reply to Thread
Results 1 to 3 of 3

Pulling data from a merged cell

  1. #1
    Registered User
    Join Date
    12-19-2023
    Location
    Singapore
    MS-Off Ver
    Microsoft 265
    Posts
    1

    Pulling data from a merged cell

    I am trying to come up with a formula which pulls data from a merged cell. Let me provide an example
    If cell P12 and Q12 shows a value of 5, i would like the respective value in cell P5 to be reflected in cell M12, so cell M12 will be where my formula is. Do let me know if this is not clear, i will try to come up with a visual to provide more context.
    I've tried extracting the data if Q12 = 5, however the problem I've been facing is as P5 and Q5 is merged, the data is stored in P5 and Q5 is an empty cell, thus it would not return anything.

    =IFERROR(TEXTJOIN(", ", TRUE, "", IF($P12:$XFD12=5, IF($P$5:$XFD$5<>"",$P$5:$XFD$5, ""),"")), "")

    This is my current formula

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    81,192

    Re: Pulling data from a merged cell

    Welcome to the forum

    Don't merge cells - use Centre Across Selection on the format menu instead.

    There are instructions at the top of the page explaining how to attach your sample workbook (yellow banner: HOW TO ATTACH YOUR SAMPLE WORKBOOK). Screenshots are of little practical use as we cannot manipulate them.

    A good sample workbook has just 10-20 rows of representative data that has been desensitised. It also has expected results mocked up, worked examples where required, relevant cells highlighted and a few explanatory notes.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,494

    Re: Pulling data from a merged cell

    If you have merged P12:Q12 then you have lost whatever was in Q12. You can only now refer to cell P12 to test a condition or return a value. You would have had a warning when you attempted to merge the cells and you have presumably ignored or accepted the warning.
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


+ 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. Replies: 2
    Last Post: 06-12-2022, 12:28 PM
  2. Merged cell error on copy/paste, but no merged cells
    By OmniBlue in forum Excel General
    Replies: 3
    Last Post: 07-15-2019, 02:15 PM
  3. Replies: 1
    Last Post: 09-27-2018, 11:22 AM
  4. [SOLVED] Pulling Data into and from Merged Cell
    By AFIOF719 in forum Excel General
    Replies: 1
    Last Post: 04-11-2018, 04:23 PM
  5. Limit merged cell data; Place excess into next merged cell down
    By coreytroy in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-06-2013, 10:35 PM
  6. Pulling a Specific Cell when Pulling a Tabel from Web Based Data
    By Zallen89 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-26-2013, 05:39 PM
  7. [SOLVED] VB:ClearContents Error on Merged Cell - But I dont have Any Merged Cell
    By cychua in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 01-24-2013, 06:33 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