Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Mac > Excel Office for Mac > Re: select case...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 2 of 2 Topic 5595 of 6461
Post > Topic >>

Re: select case arguments

by "Mike Middleton" <mike@[EMAIL PROTECTED] > May 5, 2008 at 11:36 PM

c1802362 or Art  -

What is the text string test_string? Where is it defined and how?

For example, in a standard module, this works:

Sub test()
test_string = "first header"
Select Case test_string
    Case Is = "first header"
    MsgBox "First Header"
    Case Is = "second header"
    MsgBox "Second Header"
End Select
End Sub

-  Mike Middleton
http://www.DecisionToolworks.com
Decision Analysis Add-ins for Excel



"c1802362" <utay1@[EMAIL PROTECTED]
> wrote in message 
news:f11cc592-73a9-4144-a083-ee07895db527@[EMAIL PROTECTED]
>I am trying to use a text string in a select case statement in VBA. To
> wit:
>
>
> Select Case test_string
>
>        Case Is = "first header"
>                statement 1
>
>        Case Is = "second header"
>                statement 2
>
>        etc
>
>    End Select
>
> I've been trying (without luck) to get VBA to recognize the text
> string.
>
> Any suggestions?
>
> Art
 




 2 Posts in Topic:
select case arguments
c1802362 <utay1@[EMAIL  2008-05-05 17:33:31 
Re: select case arguments
"Mike Middleton"  2008-05-05 23:36:09 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Oct 11 19:12:57 CDT 2008.