Philip wrote: > Well, i think we follow your comments and have made adjustments on the > page. My "JavaScript assistant" who happens to be my son, sent the > following comments and observations: > > I agree that reloading the applet each time is not a great idea and it > has been bothering me. Unfortunately it was the only way I could find > at the time to get it to work in both Netscape and IE (I am testing on > a PC). I discovered that this was because of the OnLoad command. It > appears that IE loads any applets in the HTML first and then runs the > ONLoad script code in the Body Tag. Netscape appears to do the > reverse. What a disaster. What version of Netscape are you working with on Win32?
> Thus when I would put the applet in the HTML and try to call > the code to load the first set of molecules in the onload command of > the body, Netscape was trying to call a script command on Applets that > were not loaded yet, and the whole page would lock up. The fix is to > call a setTimeout in the onload of 1 second which then calls the first > molecule load. Then it appears we can use the script cammand and not > reload the applet for each problem, and it works in both IE and > Netscape. Unfortunately, I think you still have some portability problems using OnLoad. It usually isn't working on Mozilla Linux. Here is what you should do. Forget about OnLoad. Break the problem into two separate pieces: 1. the initial load 2. the 'new problem' button For the initial load, call some JavaScript functions to get the names of the two .pdb files. Then, load these file names directly in the applet tag. For the 'new problem' button ... you mostly have that solved ... read on. > The tutorial does not take all the memory now which is good. It still > will not run under either Camino or Mozilla on the Mac side. Darn, I should have caught this earlier ... sorry. It isn't going to run on Mac OSX with anything but Safari on Panther. Neither Camino nor Mozilla has LiveConnect communications between JavaScript and Java Applets. This has been the killer problem on the Mac. It *is* possible to do it. But it is not particularly easy. It would involve some JavaScript coding similar to the .innerHTML reloading that you were using earlier. But let's get it running well on the other platforms before we tackle this. Miguel ------------------------------------------------------- SF.Net is sponsored by: Speed Start Your Linux Apps Now. Build and deploy apps & Web services for Linux with a free DVD software kit from IBM. Click Now! http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click _______________________________________________ Jmol-users mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jmol-users

