aspose file tools*
The moose likes Beginning Java and the fly likes Identifier expected, (already searched and read about this, still confused Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Identifier expected, (already searched and read about this, still confused" Watch "Identifier expected, (already searched and read about this, still confused" New topic
Author

Identifier expected, (already searched and read about this, still confused

jim gemlo
Greenhorn

Joined: Feb 24, 2004
Posts: 20
Here is my class:

getting identifier expected at the 'Class.forName'line.

This same piece of code works fine when I have it in a jsp page. Im trying to place this code in a Bean so I can remove business logic from my page. So I created this class and get the error.
thanks
Jeffrey Hunter
Ranch Hand

Joined: Apr 16, 2004
Posts: 305
You need to wrap your expressions inside a method. Right now, you have your variables declared correctly as instance variables, but you cannot have those expressions in the class scope. For instance, the following Class, though useless, represents the proper structure:

[ July 02, 2004: Message edited by: Jeffrey Hunter ]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Identifier expected, (already searched and read about this, still confused
 
Similar Threads
bean in or out scope?
storing the Unicodes in the database
How to store value in hidden field with struts 2.0?
Chained combobox fails to work
problem---how to display ArrayList of ArrayList in jsp page.