Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: converting from switch to given-when

by Athanasius (Abbot)
on Sep 25, 2012 at 03:03 UTC ( #995481=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    given ($selection) {
        when (wxID_YES()) {
    ...
            print qq[You pressed: "Cancel"\n];
        }
    }
    
  2. or download this
    #! perl
    use v5.14.1;
    ...
            default            { print qq[Invalid selection\n]     }
        }
    }
    
  3. or download this
    12:50 >perl 300_SoPW.pl
    selection is 5104
    wxID_YES is 5103
    One
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://995481]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (19)
As of 2015-07-31 21:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (282 votes), past polls