+ Reply to Thread
Results 1 to 3 of 3

IsEmptyWorksheet(ActiveSheet)

  1. #1
    Registered User
    Join Date
    01-25-2013
    Location
    Wicita, Kansas
    MS-Off Ver
    Excel 2003
    Posts
    5

    IsEmptyWorksheet(ActiveSheet)

    Hi. I am studying the book Excel 2002 VBA by Stephen Bullen et.al. and one of his examples is the following line of code:

    If Not IsEmptyWorksheet(ActiveSheet) Then Exit Sub

    He is trying to ensure that the the proceedure begins with a fresh clean work sheet. However, when I try to run it I get an error that says the "sub or function is not defined". So far none of his examples have had a problem and I was wondering why this might not be working? I am running Excell 2003. Is this function no longer support? That is the only thing I can think of. Any ideas?

    Thank you.

  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,599

    Re: IsEmptyWorksheet(ActiveSheet)

    IsEmptyWorksheet isn't an off the shelf function. Have you copied it into your workbook?

    I obviously can't see the context but I can't really see the value of the function. If you want to start with a clean sheet, you could just delete all the cells. Or you could delete the sheet and create a new one.

    Regards, TMS
    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
    Registered User
    Join Date
    01-25-2013
    Location
    Wicita, Kansas
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: IsEmptyWorksheet(ActiveSheet)

    Thank you TmShucks. You were spot on. The author made reference to the function before actually showing me the function on the next page. My bad. Sorry for wasting time. Have a good day.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

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