+ Reply to Thread
Results 1 to 3 of 3

The logic of OR

  1. #1
    Registered User
    Join Date
    03-31-2009
    Location
    Auburn Alabama
    MS-Off Ver
    Microsoft Office Excel 2007 (Windows)
    Posts
    99

    The logic of OR

    Hi,

    Can someone tell me which operator works in VBA the way the OR operator works in functions?

    I want to write an IF statement that will evaluate whether a variable is equal to any of the three punctuation marks ".", "?", or "!". But I'm not sure how to code it. I attempted the following:

    Please Login or Register  to view this content.
    Basically what I want to happen is, if the variable Character is equal to one of those three punctuation marks, a specific action will be taken, etc, etc.

    Thanks a lot!
    Last edited by CrazyFileMaker; 04-16-2009 at 06:08 AM.

  2. #2
    Forum Guru
    Join Date
    08-26-2007
    Location
    London
    Posts
    4,606

    Re: The logic of OR

    Afraid you have to do it long-hand, viz:
    Please Login or Register  to view this content.
    although you might like to look into the Select Case approach.

  3. #3
    Registered User
    Join Date
    03-31-2009
    Location
    Auburn Alabama
    MS-Off Ver
    Microsoft Office Excel 2007 (Windows)
    Posts
    99

    Re: The logic of OR

    Stephen,

    The longhand way's gonna work. But I'm checking out the Select Case approach now. Thanks for the tip! Cheers.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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