Java: illegal start of type error in try-catch-interface, why?
        Posted  
        
            by HH
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by HH
        
        
        
        Published on 2010-04-29T05:09:23Z
        Indexed on 
            2010/04/29
            5:17 UTC
        
        
        Read the original article
        Hit count: 400
        
The number of braces equals. What is the error for?
    static interface userInfo
    {
            File startingFile=new File(".");
            String startingPath="dummy";
            try{
                    startingPath=startingFile.getCanonicalPath();
            }catch(Exception e){e.printStackTrace();}
    }
Error
illegal start of type
© Stack Overflow or respective owner