• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Scripting applets.

 
Tim Uckun
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am having much problems trying to script a simple applet. I have read books, websites et al and they all say that the following shoudl work. Only it does not. What am I doing wrong?
Here is the HTML
-----------------------
<pre>
<script>
function lookupURL(){
myApplet=document.applets["fetchURL"];
myApplet.start(); // It fails here ( no such method)
s = myApplet.getCGIResult(); // If I comment out the //above it fails here
alert (s);
} // lookupURL
</script>

<center>The applet is below</center>


<APPLET name="fetchURL" "CODE="testcgiapplet.class" CODEBASE="Java" WIDTH=300 HEIGHT=100 MAYSCRIPT></APPLET>
</pre>
----------------------
I declared the function like this
public String getCGIResult()
I could post the whole applet too if anybody want it.

------------------
"There are some who call me TIM?"
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic