+ Reply to Thread
Results 1 to 5 of 5

MsgBox to display an alternative Message

  1. #1
    Registered User
    Join Date
    02-21-2012
    Location
    Lagos
    MS-Off Ver
    Excel 2007
    Posts
    67

    MsgBox to display an alternative Message

    Hi Guys,

    My Macro displays a message box with values from a range of cells that are not empty. I then put in a condition to display an alternative message when the range of cells are empty but the message box shows the message multiple times to the tune of the number of cells in the range. How do I display my alternative message only once. My VBA Code is below.

    Please Login or Register  to view this content.

  2. #2
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: MsgBox to display an alternative Message

    Try this.
    Please Login or Register  to view this content.
    If posting code please use code tags, see here.

  3. #3
    Registered User
    Join Date
    02-21-2012
    Location
    Lagos
    MS-Off Ver
    Excel 2007
    Posts
    67

    Re: MsgBox to display an alternative Message

    Hi Norie,

    Thanks for the code. It worked but throwing up error with the next line of code.

    Please Login or Register  to view this content.

  4. #4
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,643

    Re: MsgBox to display an alternative Message

    That code wasn't in the original.

    Anyway.
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    02-21-2012
    Location
    Lagos
    MS-Off Ver
    Excel 2007
    Posts
    67

    Re: MsgBox to display an alternative Message

    Thanks Norie,

    Excellent VBA Skills you have.

    It Worked.

+ 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