Hetal,

Going by Netscapes documentation on Javascript
(http://developer.netscape.com/docs/communicator/jsref/index.htm), I think
the doubleClick event is captured only by the 'document' object. So my guess
is that if you write a function myDblClickHandler() that checks for 
event.target = document.pgTest.listBox 
and then does
document.pgTest.elements[1].click()
and inside the <BODY ..> tag put "onDblClick=myDblClickHandler()" that
should work.

By putting an Alert(..) you can verify that the dblClick event is not being
captured for the listbox.

Aby

> -----Original Message-----
> From: [EMAIL PROTECTED] [SMTP:[EMAIL PROTECTED]]
> Sent: Friday, June 18, 1999 10:11 AM
> To:   [EMAIL PROTECTED]
> Subject:      [ND] Javascript problem with Netscape
> 
> Hi,
>    Netscape does not support some elements of java script which even IE
> does!!   
> 
>    I have a button btA and a list box. I want to dynamically click the
> button when
>        I double click an item in the list box. I have set the
> ExtraHTMLText property of
>        the list box to onDblClick="document.pgTest.elements[1].click();
> return false;"
> (element[1] corresponds to the btA)   
> 
>    I have confirmed that Netscape IS ABLE to recognize 
> elements[1] as btA but still it just does not execute the 
> javascript code. The code works fine in IE.
> 
>    Trying to click button btA by clicking button btB using the above code
> works fine in both IE and Netscape. 
> The code does not work only when I try to click btA by double clicking an
> element in list box.
> 
>    Is there a work around for this problem.
> 
> Thanks
> Hetal
> 
> _________________________________________________________________________
> 
> For help in using, subscribing, and unsubscribing to the discussion
> forums, please go to: http://www.netdynamics.com/support/visitdevfor.html
> 
> For dire need help, email: [EMAIL PROTECTED]
_________________________________________________________________________

For help in using, subscribing, and unsubscribing to the discussion
forums, please go to: http://www.netdynamics.com/support/visitdevfor.html

For dire need help, email: [EMAIL PROTECTED]

Reply via email to