Results 1 to 10 of 10

Thread: Error: Callee Disappeared

  1. #1
    Join Date
    Jan 2003

    Error: Callee Disappeared

    What is this error message trying to say?

    Error: The callee (server [not server application]) is not available and disappeared; all connections are invalid. The call did not execute.

    What is the cause of this error?

    I have a JavaScript code that displays the contents of an array variable in a popup window. The user can edit or add some contents into this array variable.

    The original browser window has the page with the following JavaScript code:

    <script type="text/javascript">

    // The public array variable.
    // Actually, this variable is an array of arrays;
    // the main index to this array is a string representing
    // a custom property's name.

    var ArrayValues = new Array();


    // The following function is used for debugging purposes
    // only. It displays the contents of ArrayValues in an
    // alert() dialog box.

    function exposeArray()
    content = '';
    for(var property in ArrayValues)
    var index = ArrayValues[property].index;
    var val = ArrayValues[property].value;

    content += property + '[' + index + '] = ' + val + '\n';



    // The following function is the handler to the onClick
    // event of the Edit button, the button that launches
    // a popup window.

    function showItems(property)
    // Debug: display contents of ArrayValues


    // Display the popup window

    var itemsWindow =
    window.open('http://www.mysite.com/cgi-bin/view.cgi?property=' + property);


    The popup window contains code that adds an item to the ArrayValues array variable. The updating occurs in the popup window's onUnload handler:

    // Variable "property" is a global variable.
    var property;


    function unload()
    var parentWindow = window.opener;

    if(parentWindow.ArrayValues[property] == null)
    parentWindow.ArrayValues[property] = new Array();

    parentWindow.ArrayValues.index =


    The first time the Edit button is clicked, the viewer pops up successfully. But after I made some changes in the ArrayValues array by using the popup window, the second time I clicked the Edit button, the "callee has disappeared" error message popped up. The error pointed to the line "var index = ArrayValues[property].index;" in the exposeArray() function.

  2. #2
    Join Date
    Jan 2003
    I've committed a mistake in typing the unload() function in this forum. I'm sorry. It should be this:

    // The onUnload handler. Defined in the popup window.
    // Variable 'property' is a global variable.

    function unload()
    var parentWindow = window.opener;

    if(parentWindow.ArrayValues[property] == null)
    parentWindow.ArrayValues[property] = new Array();

    parentWindow.ArrayValues[property].index =

    parentWindow.ArrayValues[property].value =


    The array ArrayValues is defined in the opener window, and is not defined in the popup window.

    ArrayValues is an array of arrays, but its indexes are strings. It is defined in the opener window like this:

    // Global variable ArrayValues
    var ArrayValues = new Array();

    The index to an element of this array is a string representing some custom properties. The array elements themselves are again arrays. And these latter arrays again have string indexes, but the only string values allowed are "index" and "value". In code,


    var property = "linkList"; // Sample property
    var indexValue = "Yahoo!"; // Sample index
    var valValue = "http://www.yahoo.com"; // Sample value

    ArrayValues[property] = new Array();

    // I can do it like this:

    // ArrayValues[property]["index"] = indexValue;
    // ArrayValues[property]["value"] = valValue;

    // But I did this:

    ArrayValues[property].index = indexValue;
    ArrayValues[property].value = valValue;


    The updating is done in the unload() function.

    In what circumstances does the "callee has disappeared" error generally occur?

  3. #3
    Join Date
    Jan 2003
    Okay. I've created a very simplified version of my program that produces the same "callee has disappeared" message.

    The codes for the main window and the popup window are shown below. To produce the error message, do the following steps:

    1. Run the main window.
    2. Click on the "Display array elements" button to view the current contents of the array MainArray.
    3. Click on the "Launch Add Array Elements popup window".
    4. On the popup window, fill the form with whatever you want. Click on the "Save and add another" button to save your data iinto the MainArray array.
    5. Close the popup window.
    6. On the main window, click on "Display array elements" button to view the updated array.

    After the last step, the error message will pop up.

    The code below is for the main window. Its file name is "main.htm".

    <title>Main Window</title>
    <script type="text/javascript">
    var MainArray = new Array();

    function init()
    // Initialize this array with sample values.

    MainArray['persons'] = new Array();

    MainArray['persons'][0] = new Array();
    MainArray['persons'][0].index = 'mother';
    MainArray['persons'][0].value = 'Mama Smith';

    MainArray['persons'][1] = new Array();
    MainArray['persons'][1].index = 'father';
    MainArray['persons'][1].value = 'Papa Smith';

    MainArray['linkList'] = new Array();

    MainArray['linkList'][0] = new Array();
    MainArray['linkList'][0].index = 'Yahoo!';
    MainArray['linkList'][0].value = 'http://www.yahoo.com';

    MainArray['linkList'][1] = new Array();
    MainArray['linkList'][1].index = 'Lycos';
    MainArray['linkList'][1].value = 'http://www.lycos.com';


    function display()
    var content = '';

    for(property in MainArray)
    content += property + ':\n';
    for(i in MainArray[property])
    content += ' '
    + MainArray[property][i].index + ' => '
    + MainArray[property][i].value + '\n';

    content += '\n\n';


    function addElems()
    var popupWin = window.open('popup.htm', null, 'resizable=no,width=550,height=400,status=no,scrollbars=yes');

    <body onload="javascript:init()">
    <form name="mainForm">
    <input type="button" value="Display array elements" onclick="javascript:display();"><br>
    <input type="button" value="Launch Add Array Elements popup window" onclick="javascript:addElems();">

    The code below is now for the popup window. Its file name is "popup.htm".

    <title>Add Array Elements</title>
    <script type="text/javascript">
    var parentWindow;
    var pform;

    function init()
    parentWindow = window.opener;
    pform = document.popupForm;

    function saveItems()
    var property = pform.propertyField.value;
    var indexValue = pform.indexField.value;
    var valValue = pform.valueField.value;

    if(parentWindow.MainArray[property] == null)
    parentWindow.MainArray[property] = new Array();

    var itemArray = new Array();

    itemArray.index = indexValue;
    itemArray.value = valValue;


    pform.indexField.value = '';
    pform.valueField.value = '';



    <body onload="javascript:init()">
    <form name="popupForm">
    Property: <input type="text" name="propertyField" size=30><br>
    Index: <input type="text" name="indexField" size=30><br>
    Value: <input type="text" name="valueField" size=30><br>
    <input type="button" value="Save and add another" onclick="javascript:saveItems()">

  4. #4
    Join Date
    Jan 2003
    I've also attached my source code (Opalblue.zip).

  5. #5
    Join Date
    Jan 2003
    You're right. This line is in the main window:

    var index = ArrayValues[property].index;

    And this line is in the popup window:

    parentWindow.ArrayValues[property] = new Array();

    Now I realized that the new Array() object is not created in the main window.

  6. #6
    Join Date
    Aug 2005
    i'm also facing a similar problem, if you would have got any solution to it please let me know.



  7. #7
    Join Date
    Jan 2006
    Warwickshire, England


    I've got a similar problem with an application I'm working on in C# (.NET 2002)

    I'm getting this JavaScript error message:

    "The callee (server [not server application]) is not available and
    disappeared; all connections are invalid. The call did not execute."

    This is the situation:

    The homepage has several usercontrols. The important ones are
    1. A User control that provides a menu bar.
    This menu bar contains 4 links - 2 are to external websites, the other 2 are links to open internal modeless popup windows.
    2. A user control that provides a link to a pdf document, which is opened using acrobat in IE.

    Scenario1: When I go into the homepage, and click the link, everything's fine - the pdf is displayed.

    Scenario2: Click the menu control for one of the external sites. This opens in new window. Return focus to the homepage of my site and click the pdf link. Everything's fine - the pdf is displayed.

    Scenario3: Click this menu control to open one of the popups. The popup is displayed correctly as a modeless dialog window. Return focus to the homepage and click the pdf link.
    In this scenario, the page will not open. In the development environment the code breaks with the above message. This happens regardless of whether the popup window is still open, or has ben closed.

    The user control for the pdf link looks like this:
    <%@ Control Language="c#" AutoEventWireup="false" Codebehind="PdfLinkUserControl.ascx.cs" Inherits="MyCompany.Web.UI.UserControls.HomePage.PdfLinkUserControl" TargetSchema="http://schemas.microsoft.com/intellisense/ie5"%>

    <a style="FONT-WEIGHT: bold; COLOR: #000000" href="JavaScriptopupWindow('Document/PDF/MyDocument.pdf')">
    <img src="Images/Icons/icon_download_r_24.gif" border="0">&nbsp;Click Here&nbsp; </a>

    The function is in a separate .js file in the solution
    function popupWindow(sUrl)

    Any help on this would be greatly appreciated, thanks for taking the time to read it all

    By the way, I've seen a lot of sites suggest that this has to do with popup blockers, but I don't have any, so I know its not that in this case.

    Thanks again

  8. #8
    Join Date
    Apr 2007


    Well, I have fixed the source from opalblue and it is working now without showing the 'callee' error.

    Here is what I found out and fixed -
    There is problem if Array object is passed between base and popup window. So, instead of passing array object from popup to base window, I passed simple parameters to base window function and let that function handle the array manipultation. And it worked.

    I am uploading the fixed version of the source code. Thanks to opalblue for giving easy way to recreate the issue.

  9. #9
    Join Date
    Apr 2009

    JavaScript (not Java) Discussion and technical support, including AJAX and frameworks

    The same error happened to me also but not like the one as the previous threads but possibility of these kind of errors happening is more .
    Code with error
    function dca_displayDetails_open() {

    wx = 870;
    wy = 500;
    x = (screen.width - wx) / 2;
    y = (screen.height - wy) / 2;

    dca_displayDetails_open = window.open(open_url,"dca_displayDetails_open","left="+x+",


    if you see the above code i have used the same name for the function name and the window name. this is the problem and the same was rectified by using a different code as below

    Recified code
    function dca_displayDetails_open() {

    wx = 870;
    wy = 500;
    x = (screen.width - wx) / 2;
    y = (screen.height - wy) / 2;

    dca_displayDetails = window.open(open_url,"dca_displayDetails","left="+x+",


  10. #10
    Join Date
    Oct 2010
    Thanks all. This thread was helpful as I was doing the same thing -- passing an array from a child window to the parent, closing the child and then getting this error when I tried to access the array again.

    The odd part is that neither Google Chrome nor Firefox gave me an error but IE did.

    My solution was simply to copy the array instead of assign it. This article was very useful in understanding why that was needed: http://my.opera.com/GreyWyvern/blog/show.dml/1725165

    Basically the array I passed from the child window was destroyed along with the child window so accessing it was no longer valid. So instead of doing:
    myarray = newarray;
    I simply changed it to:
    myarray = newarray.slice(0);
    Where slice copies the array from element 0 on rather than passes it by reference.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center



X vBulletin 4.2.2 Debug Information

  • Page Generation 0.15075 seconds
  • Memory Usage 2,964KB
  • Queries Executed 15 (?)
More Information
Template Usage (32):
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_global_above_footer
  • (1)ad_global_below_navbar
  • (1)ad_global_header1
  • (1)ad_global_header2
  • (1)ad_navbar_below
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)ad_thread_first_post_content
  • (1)ad_thread_last_post_content
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)headinclude_bottom
  • (10)memberaction_dropdown
  • (1)navbar
  • (4)navbar_link
  • (1)navbar_moderation
  • (1)navbar_noticebit
  • (1)navbar_tabs
  • (2)option
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available (6):
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files (26):
  • ./showthread.php
  • ./global.php
  • ./includes/class_bootstrap.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/functions_navigation.php
  • ./includes/class_friendly_url.php
  • ./includes/class_hook.php
  • ./includes/class_bootstrap_framework.php
  • ./vb/vb.php
  • ./vb/phrase.php
  • ./includes/functions_facebook.php
  • ./includes/functions_calendar.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_notice.php
  • ./packages/vbattach/attach.php
  • ./vb/types.php
  • ./vb/cache.php
  • ./vb/cache/db.php
  • ./vb/cache/observer/db.php
  • ./vb/cache/observer.php 

Hooks Called (70):
  • init_startup
  • friendlyurl_resolve_class
  • init_startup_session_setup_start
  • database_pre_fetch_array
  • database_post_fetch_array
  • init_startup_session_setup_complete
  • global_bootstrap_init_start
  • global_bootstrap_init_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • load_show_variables
  • load_forum_show_variables
  • global_state_check
  • global_bootstrap_complete
  • global_start
  • style_fetch
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • strip_bbcode
  • friendlyurl_clean_fragment
  • friendlyurl_geturl
  • forumjump
  • cache_templates
  • cache_templates_process
  • template_register_var
  • template_render_output
  • fetch_template_start
  • fetch_template_complete
  • parse_templates
  • fetch_musername
  • notices_check_start
  • notices_noticebit
  • process_templates_complete
  • friendlyurl_redirect_canonical
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • memberaction_dropdown
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • build_navigation_data
  • build_navigation_array
  • check_navigation_permission
  • process_navigation_links_start
  • process_navigation_links_complete
  • set_navigation_menu_element
  • build_navigation_menudata
  • build_navigation_listdata
  • build_navigation_list
  • set_navigation_tab_main
  • set_navigation_tab_fallback
  • navigation_tab_complete
  • fb_like_button
  • showthread_complete
  • page_templates