[Razor] How to use OnEvent on in "Select"

  1. #1

    [Razor] How to use OnEvent on in "Select"

    In this Example: http://examples2.ext.net/#/GridPanel.../Form_Details/
    It use
    <Select OnEvent="RowSelect" Buffer="250">
                                        <EventMask ShowMask="true" Target="CustomTarget" CustomTarget="#{FormPanel1}" />
                                        <ExtraParams>
                                            <%--or can use params[2].id as value--%>
                                            <ext:Parameter Name="EmployeeID" Value="record.getId()" Mode="Raw" />
                                        </ExtraParams>
                                    </Select>
    I try convert to Razor:
    .SelectionModel(gaSelectionModel => {
    gaSelectionModel.Add(Html.X().RowSelectionModel().DirectEvents(garowdirecteve => {
    garowdirecteve.Select.ExtraParams.Add(Html.X().Parameter().Name("ga_id").Value("record.getId()").Mode(ParameterMode.Raw));
              }));
    })
    But I cannot use OnEvent.
    Last edited by delta; Oct 22, 2012 at 5:24 AM.
  2. #2
    Event can be used under WebForm only
    In MVC application, you have to use Url points to controller action
    Vladimir Shcheglov
    Sr. Developer
  3. #3
    My boss request me use Javascript, Can I use it to call Javascript
    .SelectionModel(gaSelectModel => {
                   gaSelectModel.Add(Html.X().RowSelectionModel().Listeners(garowSelectListen => {
                   garowSelectListen.Select.Handler = "gaSelectBind();";
             }));
    })

Similar Threads

  1. GridPanel ext:RowEditing OnEvent "Edit"
    By xtremexploit in forum 2.x Help
    Replies: 2
    Last Post: Aug 23, 2012, 10:42 PM
  2. Replies: 1
    Last Post: Jun 21, 2012, 2:58 PM
  3. Replies: 5
    Last Post: May 02, 2012, 6:37 PM
  4. Replies: 4
    Last Post: Oct 11, 2011, 3:42 AM
  5. Replies: 2
    Last Post: Jun 26, 2011, 2:59 AM

Posting Permissions