Conditional assignment?

  • Thread starter Thread starter Maury Markowitz
  • Start date Start date
M

Maury Markowitz

I can't believe this hasn't come up in my code before...

Does VBA have a conditional assignment function? Like...

msg = (user = "Maury") ? "Foo" : "Bar"

Maury
 
Nothing as concise as that but you can use iif instead of if
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top