+ Reply to Thread
Results 1 to 2 of 2

Help with a Macro that will check if the cell is blank and pull data from sheet2

  1. #1
    Registered User
    Join Date
    07-14-2014
    Location
    Wakefield
    MS-Off Ver
    2007
    Posts
    1

    Help with a Macro that will check if the cell is blank and pull data from sheet2

    Hi,

    I need help to write a macro that will first of all check if a cell is blank and, if it is blank will then pull data from another sheet within the same workbook.

    The data will be different for every entry so it would somehow have to then find the corresponding ref on the second sheet and pull through the data contained in a specific column on the same row.

    Any ideas???

    If you need me to elaborate I can do.

    Many thanks,

    Melanie

  2. #2
    Forum Expert ben_hensel's Avatar
    Join Date
    01-26-2012
    Location
    Northeast USA
    MS-Off Ver
    Office 365
    Posts
    2,043

    Re: Help with a Macro that will check if the cell is blank and pull data from sheet2

    I dunno that you need a Macro to do this.

    Like:
    B1 = IF( ISBLANK(A1), sheet2!B1, "")

    That will do the first half of the request, checking if a cell is blank and going and grabbing data from another cell if it is.

    The second half sounds like it could be a lookup. Well, whether it's straight-forward and easy, or super-aggrevating, depends on what exactly is "somehow" different. Like, what's the corresponding reference?

    Can you post an example spreadsheet, and explain the second half more concretely?

+ 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] Macro to pull imported data from sheet2 and place data in specific rows on sheet1
    By PatRiot199 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 02-05-2013, 04:22 PM
  2. Macro to pull data from sheet1 to sheet2
    By rupss01 in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 12-11-2011, 02:29 AM
  3. Replies: 15
    Last Post: 01-19-2011, 11:37 PM
  4. Pull data from sheet2 to sheet1 help
    By lilc420 in forum Excel General
    Replies: 3
    Last Post: 08-23-2010, 12:34 AM
  5. Macro to check for blank cell entry, copy previous value, and check for duplicates
    By xPunxNotDeadx in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-26-2009, 06:33 PM

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