Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium


DrawPanel class

Posted on 2009-02-19
Medium Priority
Last Modified: 2012-05-06
hi ,
 i just type a program from a book that has a line
 DrawPanel panel = new DrawPanel();

 Eclipse said errors. I import javax.swing.JFrame already. Please advise.
Question by:valleytech
  • 3
  • 2
LVL 92

Expert Comment

ID: 23686573
whats the error

use eclipse to resolve your imports
Source>Organise imports

LVL 86

Expert Comment

ID: 23686591
Can you post the exact error please?

Author Comment

ID: 23686631
error message: DrawPanel cannot resolve to a type
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!


Author Comment

ID: 23686639
what should i import?
LVL 92

Accepted Solution

objects earned 300 total points
ID: 23686653
tun Organize Imports from your eclipse source menu

if that does not fix it then check that DrawPanel is in your build path and it is declared as a public class


Author Comment

ID: 23686769
i got it because after declare DrawPanel panel = new DrawPanel(); I  must create a DrawPanel class immediately :)
Thanks a lot.

Featured Post

[Webinar On Demand] Database Backup and Recovery

Does your company store data on premises, off site, in the cloud, or a combination of these? If you answered “yes”, you need a data backup recovery plan that fits each and every platform. Watch now as as Percona teaches us how to build agile data backup recovery plan.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

After being asked a question last year, I went into one of my moods where I did some research and code just for the fun and learning of it all.  Subsequently, from this journey, I put together this article on "Range Searching Using Visual Basic.NET …
Java Flight Recorder and Java Mission Control together create a complete tool chain to continuously collect low level and detailed runtime information enabling after-the-fact incident analysis. Java Flight Recorder is a profiling and event collectio…
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
Suggested Courses

581 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question