Passing parameters to an applet from a var in script

Discussion in 'Javascript' started by Bob Moors, Dec 6, 2003.

  1. Bob Moors

    Bob Moors Guest

    How do you make a var or function known outside of the script?

    I wrote a function that returns an int, I would like to use the function to
    set a parameter of an applet.
    I keep getting the error "Number Format Exception parsing N_ROWS parameter"
    in the MS Java Console
     
    Bob Moors, Dec 6, 2003
    #1
    1. Advertisements

  2. Bob Moors wrote:

    > How do you make a var or function known outside of the script?


    Not at all? JavaScript variables and functions cannot exist out of
    JavaScript context. All you can do is pass their identifier and/or
    value (separately).

    > I wrote a function that returns an int,


    You do not since there is no `int' type in JavaScript. You most
    certainly return a value of type `number'.

    > I would like to use the function to set a parameter of an applet.


    Get a reference to the applet object and do it then if the DOM of
    the target UA supports it.

    > I keep getting the error "Number Format Exception parsing N_ROWS parameter"
    > in the MS Java Console


    42.

    (Well, what did you expect?)


    PointedEars
     
    Thomas 'PointedEars' Lahn, Dec 8, 2003
    #2
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Alvin Bruney

    Threads.. Session var lost, App var ok

    Alvin Bruney, Dec 2, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    538
    rooster575
    Dec 2, 2003
  2. thomson
    Replies:
    10
    Views:
    2,779
    Eliyahu Goldin
    Jun 20, 2005
  3. thomson
    Replies:
    0
    Views:
    540
    thomson
    Jun 20, 2005
  4. Gabriele
    Replies:
    0
    Views:
    664
    Gabriele
    Dec 14, 2003
  5. Fred
    Replies:
    3
    Views:
    481
    Alf P. Steinbach
    Aug 10, 2003
  6. Alex Vinokur
    Replies:
    4
    Views:
    675
    Ron Natalie
    Sep 24, 2003
  7. Tor Erik Soenvisen
    Replies:
    14
    Views:
    810
    Tim Roberts
    Nov 23, 2006
  8. Michal Sza

    Passing var to anoter script

    Michal Sza, Sep 20, 2007, in forum: Ruby
    Replies:
    4
    Views:
    209
    Bertram Scharpf
    Sep 21, 2007
Loading...