This week's book giveaway is in the Java 8 forum.
We're giving away four copies of Java 8 in Action and have Raoul-Gabriel Urma, Mario Fusco, and Alan Mycroft on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes Why this is giving error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Why this is giving error" Watch "Why this is giving error" New topic
Author

Why this is giving error

Anchit Jindal
Greenhorn

Joined: Feb 03, 2010
Posts: 21
The code at
http://pastebin.com/diz9Q9sm
is giving the following error:

B.java:17: <identifier> expected
b.print();

1 error

Please explain the reason

Thanks a lot...
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 36579
    
  16
The line in question is outside a method.
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Please just paste your code into your messages; the syntax highlighting is good enough and saves us a step. Thanks! :)
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Why this is giving error
 
Similar Threads
invalid key error
Sorting arrayLIst containing value objects
TAke data from page through session
String concentation
using SOAPFaultException