Help....window.opener problem!!

Discussion in '.NET' started by JerseyKatt, Jun 18, 2007.

  1. JerseyKatt

    JerseyKatt

    Joined:
    Jun 18, 2007
    Messages:
    1
    Hi,
    I'm fairly new to javascript.
    I have a calling window that has a popup window. The sequence of events should be:
    1 - click Add New button on calling window
    2 - click on hyperlink which brings up the popup
    3 - select a record from popup, which then closes the popup, and sends some data back to calling window.
    4 - fill in rest of data on calling window, click Save button

    All works fine the first time I add a record. After selecting a record on the popup window the second time, the Save button does not fire, nor do any other actions. I cannot click on any buttons or hyperlinks on the calling page. It just sits there. I can fill in text boxes, but nothing else.

    Here is the code from my calling window:

    string scr1 = @"<script>
    var win1;

    function openCustomer(){
    win1 = open('../Common/popupCustomerParent.aspx',null,'left=300, top=100, height=600, width= 800, status=no, resizable= no, scrollbars= yes, toolbar= no,location= no, menubar= no');
    }

    function updateCustomer(elemValue)
    {
    document.getElementById('ctl00_ContentPlaceHolder1_hidCustomerParentID').innerText=elemValue[0];
    document.getElementById('ctl00_ContentPlaceHolder1_txtCustomerParentName').innerText=elemValue[1];
    document.getElementById('ctl00_ContentPlaceHolder1_hidCompanyName').innerText=elemValue[1];
    Sys.WebForms.PageRequestManager.getInstance()._doPostBack( '" + lnkbtnChooseCustomerParent.ClientID + "', 'updateDropDown' ); win1.close(); window.opener.focus(); " +
    "} </script>";

    I tried window.opener.location.reload() and that didn't work either. The odd thing is that it did work once with the location.reload and once with the focus, but stopped working in both scenarios.

    Can anyone help?? I'm going crazy!:bawling:
    JerseyKatt, Jun 18, 2007
    #1
    1. Advertising

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. Andrew Bewley via DotNetMonster.com

    window to window communication (window.opener)

    Andrew Bewley via DotNetMonster.com, Feb 3, 2005, in forum: ASP .Net
    Replies:
    0
    Views:
    1,027
    Andrew Bewley via DotNetMonster.com
    Feb 3, 2005
  2. Urs Gubler
    Replies:
    0
    Views:
    142
    Urs Gubler
    Jul 2, 2003
  3. Yaron C.

    opener.opener ?

    Yaron C., Oct 30, 2003, in forum: Javascript
    Replies:
    4
    Views:
    202
    Yaron C.
    Nov 2, 2003
  4. JPL Verhey
    Replies:
    4
    Views:
    146
    JPL Verhey
    Feb 14, 2005
  5. jojowebdev@gmail.com

    window.opener, form.opener?

    jojowebdev@gmail.com, Jul 14, 2006, in forum: Javascript
    Replies:
    5
    Views:
    272
    jojowebdev@gmail.com
    Jul 14, 2006
Loading...

Share This Page