Please be careful to use the "Post Reply" button, and not the "New Topic" button.
That's way too much irrelevant code to go through and try to understand. What does it do now, what would you like it to do, and where are you stuck making progress?
You posted close to 600 lines of code. As I said, that's way too much for people to go through and try to make sense of. At least tell us the lines numbers and variable names that you're talking about, and -just as important- what is and isn't happening according to your expectations.
Ulf Dittmer wrote:You posted close to 600 lines of code. As I said, that's way too much for people to go through and try to make sense of. At least tell us the lines numbers and variable names that you're talking about, and -just as important- what is and isn't happening according to your expectations.
First of all thank you sir for your concern show toward putting me through. According to what you asked me to do:
I have problem in line 398, I have to click in that Jbutton to call up another applet file/window - I am familiar with calling up JFrame windows but not Applet windows.
So I want someone to put me through in doing same in Applet(That is calling up applet window from an applet by clicking a button). If possible, ignor what the codes I have there and give a simple one to demostrate it.
You'll need to add an ActionListener to the JButton that opens a new JFrame. There's nothing applet-specific about the newly-opened window (except that it shows a little message telling the user that this is an applet-opened window).
You may also want to disable the button after the window has been created, so that clicking it repeatedly doesn't open multiple windows.
Ulf Dittmer wrote:You'll need to add an ActionListener to the JButton that opens a new JFrame. There's nothing applet-specific about the newly-opened window (except that it shows a little message telling the user that this is an applet-opened window).
You may also want to disable the button after the window has been created, so that clicking it repeatedly doesn't open multiple windows.
Thank you sir. Don't be bored please, but there are somethings I want you to see with me, and these are:
First, can an applet have an actionPerformed() method in it?
Secondly, I got this line of code:
My confusion is that, I dont understand how to make use of "new URL", "otherApplet.html" and "NEWWIN" in the code.
First, can an applet have an actionPerformed() method in it?
It's not the applet that has an actionPerformed method - it's the object that implements the ActionListener interface. So any Button or JButton can have one.
Secondly, I got this line of code:
My confusion is that, I dont understand how to make use of "new URL", "otherApplet.html" and "NEWWIN" in the code.
That line of code opens a new browser window showing the "otherApplet.html" page. Have you read the javadocs of the showDocument method? Have you tried using it in your applet code?
Is this related to the window you want to open when the button is clicked? I had assumed that you want to open a Swing window, but this looks like you want a new browser window; please clarify which of these it is.
Is this related to the window you want to open when the button is clicked? I had assumed that you want to open a Swing window, but this looks like you want a new browser window; please clarify which of these it is.
Actually, its a new browser window I want to open.
I have tried out that code and its running but the button couldn't open the required window. I did it this way:
Should I use a ftp protocol like this("ftp:80///d:/Alam/Qualification.html") Or what should I do to make it callup a window browser?
Thanks
Alam Winner Loveday I.
She's out of the country right now, toppling an unauthorized dictatorship. Please leave a message with this tiny ad: