How to use Switch case In the Java
<p>I am using Neatbeans 7.0 for Java programming. I have written a Switch case for selection of the program.</p>

<pre><code>switch(menu)
        {
            case 1:
            {
                //stmt
            }
            default:
            {
                //stmt
                return;
            }
        }
</code></pre>

<p>I am getting compile time error at <code>switch(menu)</code></p>

<pre><code>The Error is "strings in switch are not supported in -source 1.6
  (use -source 7 or higher to enable strings in switch)
</code></pre>

<p>(Alt-Enter shows hints)" Can any one please help me on this.</p>
