Exception in thread "main" java.lang.RuntimeException: Uncompilable source code
<p>How can I call a non static method in main class.I am getting the folowing error in my sample console application</p>

<pre><code>Exception in thread "main" java.lang.RuntimeException: Uncompilable source code - non-static method doSomthing() cannot be referenced from a static context
        at sample.Main.main(Main.java:20)
</code></pre>

<p>and the code is,</p>

<pre><code>public class Main  {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
       doSomthing();
       System.out.print("From Main");
    }

    protected void doSomthing()
    {
        System.out.print("From Main doSomthing");
    }


}
</code></pre>
