[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 371
  • Last Modified:

setUndecorated not found

I'm sure I'm doing something stupid, but for the life of me, I don't see it.

public class myApp extends applet implements ComponentListener, Runnable, WindowListener {
...
   run() {
      Frame myFrame = new Frame( title );
      myFrame.setUndecorated( true );
      ...
   }
}

I'm getting a compile error: "cannot resolve symbol" on the setUndecorated() method.
I'm compiling under v1.4.2_06. This method has existed since 1.4.

What am I missing?
0
softechnics
Asked:
softechnics
  • 9
  • 6
  • 4
  • +2
2 Solutions
 
zzynxSoftware engineerCommented:
>> I'm getting a compile error: "cannot resolve symbol" on the setUndecorated() method.
Sure it is on the setUndecorated() method?

Can you post the exact compiler error?
0
 
CEHJCommented:
That's only available in Frame >= Java 1.4
0
 
TimYatesCommented:
setUndecorated only exists in JDK 1.4+

I guess you are using 1.3 or less...

There's nothing you can do about this (AFAIK)

Apart from upgrade to 1.4+
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
TimYatesCommented:
hehe...darn...too late ;-)
0
 
softechnicsAuthor Commented:
Read the question, guys. I'm compiling under 1.4.2_06.
0
 
CEHJCommented:
>> I'm compiling under 1.4.2_06

I doubt it ;-)
0
 
TimYatesCommented:
You can't be...otherwise it would work...

Either that, or

      Frame myFrame = new Frame( title );

is creating an object of class something.whatever.Frame, NOT java.awt.Frame
0
 
TimYatesCommented:
Try changing:

   run() {
      Frame myFrame = new Frame( title );
      myFrame.setUndecorated( true );

to:

   run() {
      Frame myFrame = new Frame( title );
      // myFrame.setUndecorated( true ); -- put this back later
      System.out.println( myFrame.getClass().getName() ) ;
      System.out.println( System.getProperty( "java.version" ) ) ;

What does it say in the java console window?
0
 
softechnicsAuthor Commented:
I found the problem. I'm compiling using ANT. The BUILD.XML file is overriding my environment variables and is compiling using an earlier java package (v1.1.8). The BUILD file was provided to me by another division within our company - not mine.
0
 
TimYatesCommented:
I think CEHJ deserved half the points with this question :-/

Glad you got it sorted though...
0
 
CEHJCommented:
>> I think CEHJ deserved half the points with this question

Only half? ;-)
0
 
TimYatesCommented:
hehehe ;-P  ;-)

ok then...60/40....my final offer ;-)
0
 
CEHJCommented:
OK - done ;-)
0
 
softechnicsAuthor Commented:
Tell me how and I'll make it happen.
0
 
TimYatesCommented:
hehehe  

*spits on palm*

;-)
0
 
TimYatesCommented:
I've asked for this question to be reopened, hopefully Venabili (the page editor) will be along in a moment or two..

Then there's a "Split Points" link just above the comment entry box which you will be able to click, and divide the points up :-)

It seems fair as we both were answering simultaneously :-D
0
 
softechnicsAuthor Commented:
Is 50/50 agreeable to you both?
0
 
CEHJCommented:
OK ;-)
0
 
TimYatesCommented:
Thanks! :-)  Hope you have a restful weekend :-)
0
 
VenabiliCommented:
Nope. Working the whole weekend. And trying to clean up and catch up in the PE staff at the same time.. :)

And you are welcome.
0
 
CEHJCommented:
:-)
0

Featured Post

Independent Software Vendors: 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!

  • 9
  • 6
  • 4
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now