Avatar of nphnhi
nphnhi
 asked on

open new window from an applet

Hello,
How to open new window from an applet.
I have an applet with one button "Edit". On click this button, I want to open new window. I used:
getAppletContext().showDocument(new URL("javascript:window.open('/eportfolio/form/editchart.jsp?type=5&chart=5', null, 'width=720, height=400, scrollbars=1, status=yes');"));
It will open new window, but the parent window (I mean the page where this applet displayed) will change the URL like: javascript:window.open('/eportfolio/form/editchart.jsp?type=5&chart=5', null, 'width=720, height=400, scrollbars=1, status=yes');
Please help me
Java

Avatar of undefined
Last Comment
CEHJ

8/22/2022 - Mon
CEHJ

>>I used: getAppletContext().showDocument(new URL("javascript ....

Why not just use a normal url?
nphnhi

ASKER
If you use a normal Url, the new window will have a toolbar, status bar.... but I don't want to have them.
CEHJ

Not entirely sure that an applet would support a JS url.
This is the best money I have ever spent. I cannot not tell you how many times these folks have saved my bacon. I learn so much from the contributors.
rwheeler23
CEHJ

>>Not entirely sure that an applet would support a JS url.

Until you can determine that question with certainty, i would try to work around it by getting the applet to actually call JS by ...? (you know what - i can't remember the name of the technology ;-)) JSObject
nphnhi

ASKER
I dont understand what you mean :(
ASKER CERTIFIED SOLUTION
CEHJ

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
CEHJ

IOW, get the applet to call a JS function that opens the kind of window you want
⚡ FREE TRIAL OFFER
Try out a week of full access for free.
Find out why thousands trust the EE community with their toughest problems.
Mick Barry

> get the applet to call a JS function that opens the kind of window you want

It already is ???
CEHJ

>>It already is ???

No, AFAICT it's trying to create an unsupported URL