Applet - Javascript communication

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Roberto Gallo

    Applet - Javascript communication

    Hi again. Thank you for previews answers.

    I have another question.... How can I inform a Javascipt, that must
    submit my Applet's data, that this same Applet has produced the data in
    question?
    Or in other words, is there any way to call a JavaScript junction within
    the Applet? Is it the best way?
    What do you suggest?

    Thank you very much again,

    Roberto Gallo.




  • Silvio Bierman

    #2
    Re: Applet - Javascript communication


    "Roberto Gallo" <robertogallofi lho@hotmail.com > wrote in message
    news:bu9fit$h4g $1@aracaju.ic.u nicamp.br...[color=blue]
    > Hi again. Thank you for previews answers.
    >
    > I have another question.... How can I inform a Javascipt, that must
    > submit my Applet's data, that this same Applet has produced the data in
    > question?
    > Or in other words, is there any way to call a JavaScript junction[/color]
    within[color=blue]
    > the Applet? Is it the best way?
    > What do you suggest?
    >
    > Thank you very much again,
    >
    > Roberto Gallo.
    >
    >
    >
    >[/color]

    Hello Robert,

    You need a Netscape JAR file name java40.jar to compile the next code but
    when running in a browser the referred classes are supplied by the
    environment.

    public Object callJS(String jsCode)
    {
    JSObject window = JSObject.getWin dow(appletInsta nce);
    window.eval(jsC ode);
    }

    Regards,

    Silvio Bierman


    Comment

    • Silvio Bierman

      #3
      Re: Applet - Javascript communication


      "Silvio Bierman" <sbierman@idfix .nl> wrote in message
      news:4008a4da$0 $324$e4fe514c@n ews.xs4all.nl.. .[color=blue]
      >
      > "Roberto Gallo" <robertogallofi lho@hotmail.com > wrote in message
      > news:bu9fit$h4g $1@aracaju.ic.u nicamp.br...[color=green]
      > > Hi again. Thank you for previews answers.
      > >
      > > I have another question.... How can I inform a Javascipt, that must
      > > submit my Applet's data, that this same Applet has produced the data in
      > > question?
      > > Or in other words, is there any way to call a JavaScript junction[/color]
      > within[color=green]
      > > the Applet? Is it the best way?
      > > What do you suggest?
      > >
      > > Thank you very much again,
      > >
      > > Roberto Gallo.
      > >
      > >
      > >
      > >[/color]
      >
      > Hello Robert,
      >
      > You need a Netscape JAR file name java40.jar to compile the next code but
      > when running in a browser the referred classes are supplied by the
      > environment.
      >
      > public Object callJS(String jsCode)
      > {
      > JSObject window = JSObject.getWin dow(appletInsta nce);
      > window.eval(jsC ode);
      > }
      >
      > Regards,
      >
      > Silvio Bierman
      >
      >[/color]

      typo: the last statement should be

      return window.eval(jsC ode);


      Comment

      • Roberto Gallo

        #4
        Re: Applet - Javascript communication

        Thank you very much

        "Silvio Bierman" <sbierman@idfix .nl> wrote in message
        news:40098227$0 $320$e4fe514c@n ews.xs4all.nl.. .[color=blue]
        >
        > "Silvio Bierman" <sbierman@idfix .nl> wrote in message
        > news:4008a4da$0 $324$e4fe514c@n ews.xs4all.nl.. .[color=green]
        > >
        > > "Roberto Gallo" <robertogallofi lho@hotmail.com > wrote in message
        > > news:bu9fit$h4g $1@aracaju.ic.u nicamp.br...[color=darkred]
        > > > Hi again. Thank you for previews answers.
        > > >
        > > > I have another question.... How can I inform a Javascipt, that[/color][/color][/color]
        must[color=blue][color=green][color=darkred]
        > > > submit my Applet's data, that this same Applet has produced the data[/color][/color][/color]
        in[color=blue][color=green][color=darkred]
        > > > question?
        > > > Or in other words, is there any way to call a JavaScript junction[/color]
        > > within[color=darkred]
        > > > the Applet? Is it the best way?
        > > > What do you suggest?
        > > >
        > > > Thank you very much again,
        > > >
        > > > Roberto Gallo.
        > > >
        > > >
        > > >
        > > >[/color]
        > >
        > > Hello Robert,
        > >
        > > You need a Netscape JAR file name java40.jar to compile the next code[/color][/color]
        but[color=blue][color=green]
        > > when running in a browser the referred classes are supplied by the
        > > environment.
        > >
        > > public Object callJS(String jsCode)
        > > {
        > > JSObject window = JSObject.getWin dow(appletInsta nce);
        > > window.eval(jsC ode);
        > > }
        > >
        > > Regards,
        > >
        > > Silvio Bierman
        > >
        > >[/color]
        >
        > typo: the last statement should be
        >
        > return window.eval(jsC ode);
        >
        >[/color]


        Comment

        Working...