ASP.NET MasterPages: ajax instance method 'xxx' is absent

Page 2 of 2 FirstFirst 12
  1. #11
    First, you have no resource manager in the page therefore directs methods will not be registered
    Second, all direct methods in the master page will have master page client id prefix, like
    App.direct.ctl00.myMethod
    Therefore you need to use that prefix (master page ClientID) or disable that prefix
    [DirectMethod(IDMode = DirectMethodProxyIDMode.None)]
    Please see
    https://examples2.ext.net/#/Events/D...thods/ID_Mode/
  2. #12
    Quote Originally Posted by Vladimir View Post
    First, you have no resource manager in the page therefore directs methods will not be registered
    Second, all direct methods in the master page will have master page client id prefix, like
    App.direct.ctl00.myMethod
    Therefore you need to use that prefix (master page ClientID) or disable that prefix
    [DirectMethod(IDMode = DirectMethodProxyIDMode.None)]
    Please see
    https://examples2.ext.net/#/Events/D...thods/ID_Mode/
    I forgot to add the resource manager when I re-created the sample, the tip to disable the proxy id is nice however I can't reproduce the error that happens on some of my pages using the sample I created, pretty much some child pages can execute the DirectMethod without a problem while a few of them throw an exception.
    Can you give me any advise as far as what could possibly interfere with the DirectMethods in a MasterPage to make it show the error bellow?:

    Message: The ajax instance method 'myMethod' is absent! Stack Trace: at Ext.Net.ResourceManager.RaisePostBackEvent(String eventArgument) at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    This works on some child pages but on a few it doesn't.
  3. #13
    If you add direct methods on the fly during development without app restart then switch to debug mode to avoid cache problems
  4. #14
    Quote Originally Posted by Vladimir View Post
    If you add direct methods on the fly during development without app restart then switch to debug mode to avoid cache problems
    I found out what the problem was, I had this on the top of my client page:

    ClientIDMode="Static"
    Do you know any workaround to use the option above without breaking the DirectMethods?
    Thanks
Page 2 of 2 FirstFirst 12

Similar Threads

  1. [CLOSED] GridPanel Layout with Masterpages
    By sisa in forum 1.x Legacy Premium Help
    Replies: 6
    Last Post: Aug 18, 2012, 1:00 PM
  2. [CLOSED] Problem with Page.X() and masterpages
    By Pablo_Azevedo in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Jun 08, 2012, 7:32 PM
  3. [CLOSED] ViewState and MasterPages
    By wisdomchuck in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: May 20, 2011, 7:58 PM
  4. Problem With editor in MasterPages & User web Control
    By firebird_design in forum 1.x Help
    Replies: 2
    Last Post: Sep 08, 2010, 1:57 PM
  5. [CLOSED] FitLayout & masterpages
    By GmServizi in forum 1.x Legacy Premium Help
    Replies: 5
    Last Post: Oct 22, 2009, 6:11 AM

Tags for this Thread

Posting Permissions