Null Reference for Ajax PopupControlExtender


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 1 of 1

Thread: Null Reference for Ajax PopupControlExtender

  1. #1
    Join Date
    Mar 2008
    Posts
    65

    Null Reference for Ajax PopupControlExtender

    Hello,

    I am attempting to a web page as a popup via Ajax PopupControlExtender but having some difficulty. When attempting to show the popup, the following error is returned:


    "JavaScript runtime error: Unable to get property 'showPopup' of undefined or null reference"


    I've tried to access the control by way of the BehaviorID, ClientID and ControlBehavior (I.e. AjaxControlToolkit.PopupControlBehavior.__VisiblePopup.showPopup(); )

    but to no avail. There are a few odd things occurring that maybe worth mentioning:

    1. I am able to show a non-modal popup with Ajax PopupControlExtender in other pages using the BehaviorID

    2. I am able to show a Modal popup (I.e. ModalPopupExtender) from the page in question with no problem.

    3. Other controls in the page can be accessed with ClientID. It's just the PopupControlExtender control whereby the null reference is returned.

    Here's a sample of the code:

    --HTML
    Code:
    <cc1:PopupControlExtender ID="test1_PopupControlExtender" 
            runat="server" DynamicServicePath="" Enabled="True" ExtenderControlID="" 
            TargetControlID="Label1" PopupControlID="Panel1" BehaviorID="test1">
        </cc1:PopupControlExtender>
    --JavaScript
    Code:
    $find('test1').showPopup();
        //AjaxControlToolkit.PopupControlBehavior.__VisiblePopup.showPopup();
        //$find('<%=form1.FindControl("test1_PopupControlExtender").ClientID%>').showPopup();
    Any help is appreciated.
    Last edited by wrappingduke; 07-26-2014 at 02:55 AM.

Similar Threads

  1. AJAX Reference Manual
    By QiSoftware in forum AJAX
    Replies: 2
    Last Post: 10-29-2007, 08:50 PM
  2. Replies: 1
    Last Post: 07-20-2006, 01:46 AM
  3. OleDbDataReader Null REference
    By sindhuja in forum .NET
    Replies: 3
    Last Post: 11-25-2005, 10:33 AM
  4. Object null reference in user control
    By Jason Salas in forum ASP.NET
    Replies: 1
    Last Post: 08-17-2003, 11:37 AM

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
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center