This is a migrated thread and some comments may be shown as answers.

RadGrid and RowClick

3 Answers 124 Views
UI for ASP.NET AJAX in ASP.NET MVC
This is a migrated thread and some comments may be shown as answers.
Brian Mains
Top achievements
Rank 1
Brian Mains asked on 29 Oct 2009, 06:41 PM
Hello,

I have a RadGrid:

<tel:RadGrid ID="MG" runat="server">
    <MasterTableView DataKeyNames="Key" AutoGenerateColumns="false"
        Width="450px">
        <Columns>
            <tel:GridTemplateColumn HeaderText="Subject">
                <ItemTemplate>
                    <a href='<%# Url.Action("Select", "Messages", new { message = DataBinder.Eval(Container.DataItem, "Key") }) %>'><%# Eval("Subject") %></a>
                </ItemTemplate>
            </tel:GridTemplateColumn>
            <tel:GridBoundColumn HeaderText="Subject" DataField="Subject" />
            <tel:GridBoundColumn HeaderText="Sent" DataField="CreatedDate" DataFormatString="{0:MM/dd/yyyy}" />
            <tel:GridBoundColumn HeaderText="Last Reply" DataField="LastReply" />
            <tel:GridBoundColumn HeaderText="Reply Date" DataField="ReplyDate" />
        </Columns>
    </MasterTableView>
    <ClientSettings EnableRowHoverStyle="true">
        <ClientEvents OnRowClick="MG_RowClick" />
        <Selecting AllowRowSelect="true" />
    </ClientSettings>
</tel:RadGrid>

The MG_RowClick event never fires in my MVC view.  The script is in the same place as my MVC view...   SelectedIndexChanged doesn't fire either.

How do I get that to work?

Thanks.

3 Answers, 1 is accepted

Sort by
0
Georgi Krustev
Telerik team
answered on 04 Nov 2009, 12:25 PM
Hello Brian,

Please try to use RadScriptManager instead of ScriptManager control.

Sincerely yours,
Georgi Krustev
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Brian Mains
Top achievements
Rank 1
answered on 04 Nov 2009, 01:50 PM
Hello,

I am using the RadScriptManager only.  I got a post back about defining the RadScriptManager after all controls, so I'll try that and see if it alleviates it.

Brian
0
Georgi Krustev
Telerik team
answered on 06 Nov 2009, 11:18 AM
Hello Brian,

Please review the attached test project which implements the suggested approach.

Best wishes,
Georgi Krustev
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
UI for ASP.NET AJAX in ASP.NET MVC
Asked by
Brian Mains
Top achievements
Rank 1
Answers by
Georgi Krustev
Telerik team
Brian Mains
Top achievements
Rank 1
Share this question
or