atw: Re: VBA Select Case Statement question.

Thanks Col.

It's the single expression I was trying to get around.

I was after:

        Select Case (This And That) <-- This is the multiple expression I
was after to allow a validation of the rest

                Case This = text And That > a value  <-- I wanted the 'And'
to be tested as well.
                        Do something
                Case This = text And That < a value  <-- I wanted the 'And'
to be tested as well.
                        Do something else

        End Select

But it looks like I can only do these with if/Else or nested Case

Thanks anyway.

Cheers,

Bruce

-----Original Message-----
From: austechwriter-bounce@xxxxxxxxxxxxx
[mailto:austechwriter-bounce@xxxxxxxxxxxxx] On Behalf Of Colin Roberts
Sent: Thursday, 23 August 2007 6:05 PM
To: austechwriter@xxxxxxxxxxxxx
Subject: atw: Re: VBA Select Case Statement question.

Hi Bruce,

There's also the option to use the True/False condition in your select
statement.

Select Case True
  Case this = that
  Case this > that
  Case this AND that
  Case Else
End Select

Hope this helps.

Cheers
Col
**************************************************
To post a message to austechwriter, send the message to
austechwriter@xxxxxxxxxxxxxx

To subscribe to austechwriter, send a message to
austechwriter-request@xxxxxxxxxxxxx with "subscribe" in the Subject field.

To unsubscribe, send a message to austechwriter-request@xxxxxxxxxxxxx with
"unsubscribe" in the Subject field.

To search the austechwriter archives, go to
www.freelists.org/archives/austechwriter

To contact the list administrator, send a message to
austechwriter-admins@xxxxxxxxxxxxx
**************************************************


--
No virus found in this incoming message.
Checked by AVG Free Edition. 
Version: 7.5.484 / Virus Database: 269.12.2/967 - Release Date: 8/22/2007
6:51 PM


**************************************************
To post a message to austechwriter, send the message to 
austechwriter@xxxxxxxxxxxxxx

To subscribe to austechwriter, send a message to 
austechwriter-request@xxxxxxxxxxxxx with "subscribe" in the Subject field.

To unsubscribe, send a message to austechwriter-request@xxxxxxxxxxxxx with 
"unsubscribe" in the Subject field.

To search the austechwriter archives, go to 
www.freelists.org/archives/austechwriter

To contact the list administrator, send a message to 
austechwriter-admins@xxxxxxxxxxxxx
**************************************************

Other related posts: