how to make Command Handler ViewStateEnabled

  1. #1

    how to make Command Handler ViewStateEnabled

    Hello All,

    Can someone tell me how to enable viewState in command handler.

    I used following code for button to use ViewState which works fine

    <ext:Button ID="btnEnable" Icon="ArrowDown" runat="server" Text="Down">
       <DirectEvents>
         <Click OnEvent="btnMoveDown_Click" ViewStateMode="Enabled">
        </Click>
       </DirectEvents>
    </ext:Button>
    but i can not find any thing to use viewstate with following
    <Listeners>
         <Command Handler="Admission.AjaxCall(command,rowIndex)" />
    </Listeners>
    if you need any more information do tell..

    Thanks and Regards
    Harshad Jadhav
  2. #2
    Please try the following.

    Example

    Admission.AjaxCall(command,rowIndex, { viewStateMode : 'enabled' })
    Geoffrey McGill
    Founder
  3. #3
    Or, adding the following property to the [DirectMethod] attribute should enable ViewState, see

    Example

    [DirectMethod(ViewStateMode = ViewStateMode.Enabled)]
    Geoffrey McGill
    Founder
  4. #4

    [CLOSED] how to make Command Handler ViewStateEnabledReply to Thread.

    Hi Geoffrey,

    Thankyou very much.

    Admission.AjaxCall(command,rowIndex, { viewStateMode : 'enabled' })


    This works .

    Thanks and Regards
    Harshad Jadhav
    Last edited by Daniil; Dec 02, 2010 at 9:56 AM. Reason: Please use [CODE] tags

Similar Threads

  1. [CLOSED] Fn vs Handler (when to use Fn and Handler)
    By hgouw in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Sep 21, 2011, 1:39 AM
  2. Row command not working
    By 78fede78 in forum 1.x Help
    Replies: 1
    Last Post: Sep 13, 2010, 10:55 AM
  3. Replies: 11
    Last Post: Apr 08, 2010, 1:36 PM
  4. How can I make a GroupHeaderPlugin
    By rhythym in forum 1.x Help
    Replies: 1
    Last Post: Nov 16, 2009, 4:37 PM
  5. Grid Command
    By marciocxs in forum 1.x Help
    Replies: 1
    Last Post: Apr 14, 2009, 5:27 PM

Posting Permissions