DirectMethods Postback control ID

  1. #1

    DirectMethods Postback control ID

    Hello!

    i have multiple buttons that used DirectMethods to call server side functions.
    how i can know the control or button id which caused postback? [i can't send the button id within the directmethod as parametre]

    thank you!
  2. #2
    Do not need to. Each control calls a method with a different name, right?
  3. #3
    Quote Originally Posted by CarlosS View Post
    i have multiple buttons that used DirectMethods to call server side functions.
    how i can know the control or button id which caused postback?
    Can you pass the Button .id as one of the arguments to the method?

    public void DoSomething(int someValue, string buttonId)
    {
        var button = buttonId;
    }
    [i can't send the button id within the directmethod as parametre]
    Why not?
    Geoffrey McGill
    Founder
  4. #4
    Because my target is to capture each button clicked in a page, and i want only to write one function in one Base Page that in Page_Load Or Init capture the buttons id, so i tried to get the value of __EVENTTARGET but it will show that the ResourceManager is the control which caused post Back, so can i grab from the ResourceManager the Control id triggering the DirectMethods?

Similar Threads

  1. Replies: 1
    Last Post: Apr 03, 2012, 9:36 AM
  2. Replies: 2
    Last Post: Mar 10, 2011, 3:02 PM
  3. Ext control invisible after postback of page.
    By Rupesh in forum 1.x Help
    Replies: 7
    Last Post: Sep 17, 2010, 5:11 AM
  4. Control exclude in ajax postback
    By jeybonnet in forum 1.x Help
    Replies: 2
    Last Post: Jan 17, 2009, 6:57 PM
  5. Replies: 4
    Last Post: Nov 25, 2008, 5:53 PM

Posting Permissions