+ Reply to Thread
Results 1 to 6 of 6

Search a sheet for content

  1. #1
    Forum Contributor
    Join Date
    01-18-2013
    Location
    London
    MS-Off Ver
    Excel 2003
    Posts
    641

    Search a sheet for content

    I wonder if someone can advise on a small macro.

    I'd like to search my workbook for a 'sheet1'. It doesn't need to be opened necessarily , but the macro should check it for any content.

    Where sheet1 has no content and is empty , a popup would state 'No Content in sheet1'.

    Where sheet1 has content , end the macro with no further message or action.

    Can someone help with some VBA to satisfy this?

    Grateful for any help.

    Using Excel , Word and Access 2003 - For the whole of 2024

  2. #2
    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,902

    Re: Search a sheet for content

    Maybe this:

    Please Login or Register  to view this content.
    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


  3. #3
    Forum Contributor
    Join Date
    01-18-2013
    Location
    London
    MS-Off Ver
    Excel 2003
    Posts
    641

    Re: Search a sheet for content

    Thanks TMS - this does the job perfectly.

  4. #4
    Forum Expert
    Join Date
    10-06-2017
    Location
    drevni ruchadlo
    MS-Off Ver
    old
    Posts
    2,158

    Re: Search a sheet for content

    A small modification to TMS code:
    Please Login or Register  to view this content.

  5. #5
    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,902

    Re: Search a sheet for content

    You're welcome. Thanks for the rep.

  6. #6
    Forum Contributor
    Join Date
    01-18-2013
    Location
    London
    MS-Off Ver
    Excel 2003
    Posts
    641

    Re: Search a sheet for content

    Thanks guys.

+ 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: 01-17-2020, 12:16 AM
  2. Unable to search for content in hidden protected sheet
    By kevb8ll in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-13-2018, 03:47 AM
  3. VBA - Search for content and merge
    By lourensjc in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-11-2013, 11:48 AM
  4. [SOLVED] Search content from cell A1 in Sheet2 and select the content found
    By excelcandy in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-04-2013, 06:45 PM
  5. [SOLVED] Macro to search for a string and copy its row content to another sheet
    By akynyemi in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 04-25-2013, 06:13 AM
  6. [SOLVED] If cell X's content in Sheet A equals to cell Y's content in Sheet B, Then copy some data.
    By sunheroj in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 08-09-2012, 09:25 AM
  7. How to search and copy cell content to another sheet?
    By Roel in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 03-07-2005, 10:06 AM

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