File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Beginning Java and the fly likes ArrayList driving me crazy !!!!! Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "ArrayList driving me crazy !!!!! " Watch "ArrayList driving me crazy !!!!! " New topic
Author

ArrayList driving me crazy !!!!!

manolo zapata
Greenhorn

Joined: Apr 28, 2008
Posts: 2
Ok guys begginer here, I have a problem that drives me crazy

I try to create an arraylist but I keep getting identifier expected and '(' or '[' expected errors, I thought its something I do, but I copied and tried an example snippet from the net and exactly the same, I use 1.6 sdk

here's the example snippet



and the error I get is :




can anyone help it is killing me !!!

thanks

[ April 28, 2008: Message edited by: manolo zapata ]
[ April 28, 2008: Message edited by: manolo zapata ]
Stevi Deter
Ranch Hand

Joined: Mar 22, 2008
Posts: 265

Manolo,
Are you sure Java 6 is the first JDK on your path?

Assuming you're on windows, open a command line, and type "PATH" and see what's there.

It looks like the version of javac being found is Java 1.4 or earlier (pre-Generics). The example code you gave runs fine on my system with Java 6.


There will always be people who are ahead of the curve, and people who are behind the curve. But knowledge moves the curve. --Bill James
manolo zapata
Greenhorn

Joined: Apr 28, 2008
Posts: 2
I had a look and it seems you are right

it goes through 1.4.2 first

I will try and fix this ,

thanks very much for the help (dont go away sorta speak, I bet I'll need more help with this )


thanks a lot man
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: ArrayList driving me crazy !!!!!