File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Compile issue -- misplaced construct error

 
Vraj Desai
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi im using ready to program and after writing this code into the program i get a misplaced construct error.

please help i dont know what i did wrong.




the exact error : misplaced construct(s)

it highlights this line
import java.awt.*; 2nd line

at the very start and gives me the misplaced construct error

Yes this is all the code i have written down.

[Edit - added code tags - see UseCodeTags]
 
Matthew Brown
Bartender
Posts: 4549
8
Java Netbeans IDE Scala
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Vraj. Welcome to The Ranch!

The compiler should tell you what line the error is occurring on. That should give you a good clue as to what's gone wrong, but if it's not enough can you tell us what line it is?
 
Henry Wong
author
Marshal
Pie
Posts: 20829
75
C++ Chrome Eclipse IDE Firefox Browser Java jQuery Linux VI Editor Windows
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
[EDIT -- changed the subject title to something more informative than "Helppp !!".]
 
Praveen Kumar M K
Ranch Hand
Posts: 256
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you have all the code that you've posted here, in one file?
 
Consider Paul's rocket mass heater.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic