typeof on applet method suddelny stopped working...

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Dag Sunde

    #1

    typeof on applet method suddelny stopped working...

    I have the following code fragment in one of my pages:

    if (typeof document.getEle mentById('myApp let').getTableA sSDV != 'undefined')
    {
    rowBuffer = document.getEle mentById('myApp let').getTableA sSDV();
    }

    The code above have been working in IE, NS anf Firefox for a long time now,
    but have suddenly stopped working in IE 6, on WIN XP SP1.

    It now returns 'undefined', so my rowbuffer never get set.

    For the record:
    typeof document.getEle mentById('myApp let') returns 'object',
    so the applet is found.

    It still work on other browsers, and in IE on Win2000 and lower...

    Any insights on thisone?

    TIA...

    --
    Dag.


  • Martin Honnen

    #2
    Re: typeof on applet method suddelny stopped working...



    Dag Sunde wrote:
    [color=blue]
    > I have the following code fragment in one of my pages:
    >
    > if (typeof document.getEle mentById('myApp let').getTableA sSDV != 'undefined')
    > {
    > rowBuffer = document.getEle mentById('myApp let').getTableA sSDV();
    > }
    >
    > The code above have been working in IE, NS anf Firefox for a long time now,
    > but have suddenly stopped working in IE 6, on WIN XP SP1.
    >
    > It now returns 'undefined', so my rowbuffer never get set.
    >
    > For the record:
    > typeof document.getEle mentById('myApp let') returns 'object',
    > so the applet is found.[/color]

    If you have
    <object id="myApplet" ...>
    or
    <applet id="myApplet" ...>
    then of course
    document.getEle mentById('myApp let')
    finds that element object but whether the applet is run and exposes
    public properties is a different issue.
    Is Java enabled at all, have you checked the Java console whether there
    are any problems with the applet itself being properly initialized and
    started?

    --

    Martin Honnen
    http://JavaScript.FAQTs.com/

    Comment

    • Dag Sunde

      #3
      Re: typeof on applet method suddelny stopped working...

      "Martin Honnen" <mahotrash@yaho o.de> wrote in message
      news:4225b264$0 $24928$9b4e6d93 @newsread2.arco r-online.net...[color=blue]
      >
      >
      > Dag Sunde wrote:
      >[color=green]
      > > I have the following code fragment in one of my pages:
      > >
      > > if (typeof document.getEle mentById('myApp let').getTableA sSDV !=[/color][/color]
      'undefined')[color=blue][color=green]
      > > {
      > > rowBuffer = document.getEle mentById('myApp let').getTableA sSDV();
      > > }
      > >
      > > The code above have been working in IE, NS anf Firefox for a long time[/color][/color]
      now,[color=blue][color=green]
      > > but have suddenly stopped working in IE 6, on WIN XP SP1.
      > >
      > > It now returns 'undefined', so my rowbuffer never get set.
      > >
      > > For the record:
      > > typeof document.getEle mentById('myApp let') returns 'object',
      > > so the applet is found.[/color]
      >
      > If you have
      > <object id="myApplet" ...>
      > or
      > <applet id="myApplet" ...>
      > then of course
      > document.getEle mentById('myApp let')
      > finds that element object but whether the applet is run and exposes
      > public properties is a different issue.
      > Is Java enabled at all, have you checked the Java console whether there
      > are any problems with the applet itself being properly initialized and
      > started?[/color]

      Yes to all of the above...
      The applet is alive & kickin' when the problem occurs...
      No problems in the console...
      Java is definitely enabled (Sun plugin 1.4.2_06)

      The above test was to check if my applet actually had a method called
      "getTableAsSDV( )" before calling it, but that suddenly stopped working
      in IE/XP.

      I've changed the code to:
      if ( document.getEle mentById('myApp let') ) {
      document.getEle mentById('myApp let').getTableA sSDV();
      }
      instead, and all is well... (but it puzzles me...)

      --
      Dag.


      Comment

      Working...