Datagrid popup window problem

  • Thread starter Thread starter Stephen
  • Start date Start date
S

Stephen

Hi,

I have a datagrid which displays a list of names and a
button next to each name. In the Datagrid_ItemDataBound
event I attach an attribute to each button which sets the
onclick event of each button to a javascript window.open
event that opens up a popup window, the only problem is
that when I push the button, the new window displays but
the other window re_loads itself and after a few seconds
focus is taken away from the new window, back to the
opener, is there any way of stopping this from happening?

Any help with this would be greatly appreciated
Thanks
Stephen
 
Stephen:

Ive done this several times. Sounds like the form is doing a postback when
the window is being opened. You can suppress it by calling return false
after the javascript window.open command. The other option is to use an
HtmlInputButton control, but this has proved to be a PIA for me.

HTH
 
Back
Top