You need to sign in to do that
Don't have an account?

Select Case construct
Hi,
Is there a similar Select Case construct in Apex? I use this Select Case construct from .Net platform as an example.
Please advice. Thanks
Select
statement1..
End Select
Case
Nope, there is no Select Case or Switch statement right now in Apex. Your best bet is to use a bunch of IFs.
Jeremy
ultimate fail- nested if statements are so 90s.
For those visiting this post, promote the idea
Add "Switch" or "Case" Statement to Apex: https://sites.secure.force.com/ideaexchange//apex/ideaview?id=08730000000BrSIAA0