Jennifer Wallace

Ranch Hand
+ Follow
since Nov 30, 2001
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Jennifer Wallace

Thanks! I am about to do that. I am planning on looking into the Sun tutorial first.
17 years ago
Can somebody tell me if Javaswing is nothing but swing ?
Pardon my ignorance.
17 years ago
I am looking for some ideas on how to do this and pointers to books or web resources here.
I have two lists "A" and "B", where for every value of A there is a value of "B". I want to set up a small search facility on my website. Just a little thing where for every value of "A" chosen, the corresponding value of "B" should be displayed.
How do I do this? Set up a database or flat file ? Either way, what tools are recommended and how to set this up? Do help!
I think Mouse Listeners will not work for me because I want the applets components to be validated when the web page containing the applet gains focus and not wait until the mouse enters the applet.
Also, looks like componentShown method of ComponentListener (Definiton of which is - Invoked when the component has been made invisible) doesn't correspond to the applet window going out of view and getting back focus. I think the demo applet in Sun's Website also demonstrates similar activity.
In fact, the solution would be to validate my components in the applet's paint method. And this works fine and resets my textfield everytime the applet is repainted.
19 years ago
Thanks ! validate() resets my textfield beautifully. Sorry for the delayed response. Just saw your reply today.
But looks like I have worked up with the wrong listener. Because apparently, the componentshown method of Component Listener is invoked only once initially (atleast in my code) and is not invoked when the applet is repainted on re gaining focus. This contradicts what I saw in the demo applet of java tutorial. Would this not work on applets ?
Also, I tried a couple of others. They didn't work as well - Focus Listener, WindowFocuslistener, WindowListener (the last 2 work only for windows!)
Which listener should I be using, to capture the moment of my return to the applet screen ?
Thanks,
Jennifer
19 years ago
Please look into this problem. I have tried to state the problem in simple terms.
Class A extends Canvas.
Class B extends applet and has Cardlayout
The first card is a panel,has borderlayout.
- This contains an instance of "A" in the "CENTER"
- Also, has a panel with a textfield in "SOUTH"
When I leave the browser window containing the applet, and return.
the Canvas in the center is repainted and refreshes itself. But the lower panel is not reset. (The textfield still retains the previous state).
To reset the textfield, I tried to implement class B as a ComponentListener and tried reseting the textfield values in
componentShown(ComponentEvent ce) method of the inteface. Doesnt seem to work on the textfield ?
Is this the right approach ? if so, why would this be not working ?
[ June 26, 2002: Message edited by: Jennifer Wallace ]
19 years ago
Thanks Timothy ! Straight solution.
I was using the mouselistener interface. But was toying around with the consume() method of InputEvent. But this is simple enough.
19 years ago
Is it possible to disable mouse clicks temporarily and enable it again when needed ? If so, how ?
Thanks,
Jennifer
[ June 13, 2002: Message edited by: Jennifer Wallace ]
19 years ago
I have trouble understanding the way 'paint' works on a Panel. Is it similar to an applet where the component is painted when it is shown and every time it is hidden and exposed.
Please look at the simple code below. I do not see the string being displayed . Where am I going wrong ?

Do update and repaint work the same way in containers like Panel as in applets ? If I invoke repaint() on the testPan in the example above, would that invoke the paint method in the class TestPan ?
[ May 30, 2002: Message edited by: Jennifer Wallace ]
[ May 30, 2002: Message edited by: Dirk Schreckmann ]
19 years ago
Rosie,
I am not an expert on applets. But see if this would be a solution.
<applet code=example.class width=100% height=100>
</applet>
Coding width as 100% should make the width of the applet as wide as the window size.
19 years ago
Thanks Manfred! It worked. It is pretty exciting to see my applet after staring at a cross for such a long time.
Regards,
Jennifer
[ May 29, 2002: Message edited by: Jennifer Wallace ]
19 years ago
Hello,
I am here back with the same persisting problem with little more details.If you have any info in this regard, do share it.
This time I downloaded Netscape 6 afresh.
When I try to open a jdk1.4 applet in my computer in Netscape, I am prompted to download the plugin.
But I have jdk 1.4(J2SE) downloaded into my computer already. Looks like the second FAQ here is pertinent to my problem. But I am at a loss as I don't know how to set it in Netscape . $javahome ? plugin path ?
Didnt make much sense to me. Could somebody explain this ?
Also, I tried getting into Control Panel > java plugin1.4 and tried setting it as default for Netscape, but I was not able to do it. Currently java plugin 1.4 in the control panel shows as default for IE but not Netscape 6.
If you can, please do shed some light on this problem.
Thanks,
Jennifer
19 years ago
Thanks Dirk for your patient replies !
19 years ago
Thanks!
Would there be a source where I could learn more details on how Browsers handle applets ? And the minor details like one browser having one feature but not another! Because I am running into weird kind of problems.
I have an applet compiled in jdk1.4 . Loads fine in IE 6. But there is nothing when the same HTML page is viewed in IE 5.5. The differences are confusing. How would you check which version of JVM is your browser capable of handling ?
19 years ago
I need help with understanding some basic concepts. I started with Sun's online Tutorial. This has raised a couple of questions.
1.What does Java Virtual Machine constitute here? Please look towards the end of this webpage
2. Is this JVM version dependent? If I create a ".class" file with jdk1.4, will that run in a machine with jdk 1.3 (if the features/classes invoked in this program are available in jdk1.3)
3.What is a Client compiler ?

3. A Web browser runs an applet . How are the Java bytecodes "interpreted" here ?
4.what is a 'PLUGIN'? what is 'Microsoft VM' ?
5. Do the major web browsers(IE and netscape) run applets (compiled with jdk1.4) properly ?
Thanks,
Jennifer
[ May 17, 2002: Message edited by: Jennifer Wallace ]
19 years ago