Problem with Menu in GridTemplateColumn

4 posts, 1 answers
  1. Paul Evers
    Paul Evers avatar
    52 posts
    Member since:
    Oct 2011

    Posted 24 Feb 2014 Link to this post

    Hi,

    I have in a RadGrid (latest version) a GridTemplateColumn. In the ItemTemplate for this GridTemplateColumn I create a RadMenu with several menuitems.
    When I open this menu the dropdown with the menuitems doesn't show beyond the borders of the row of the grid (see attached screenshot).
    How can I make the menu appear properly?

    Paul
  2. Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 24 Feb 2014 in reply to Paul Evers Link to this post

    Hi Paul Evers,

    Can you please make sure your RadGrid's TableLayout is Auto.

    ASPX:
    <MasterTableView TableLayout="Auto">

    Thanks,
    Shinu
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Paul Evers
    Paul Evers avatar
    52 posts
    Member since:
    Oct 2011

    Posted 24 Feb 2014 in reply to Shinu Link to this post

    Thank you Shinu.

    Besides the tablelayout I had also had to set ClientSettings.Resizing.AllowColumnResize to false to fix it.
    I don't understand why. I think it is strange behavior.

    Paul
  5. Answer
    Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 24 Feb 2014 in reply to Paul Evers Link to this post

    Hi Paul Evers,

    I was able to get the Menu displayed when setting TableLayout as Auto. Try setting UseStaticHeaders to false, if you are using that property. Below is a sample code snippet that I tried. Please take a look and provide your code snippet if this doesn't help.

    ASPX:
    <telerik:RadGrid ID="RadGrid1" runat="server">
        <MasterTableView TableLayout="Auto">
            <Columns>
                <telerik:GridBoundColumn  DataField="OrderID" HeaderText="OrderID">
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="ShipCity" HeaderText="ShipCity" />
                <telerik:GridTemplateColumn>
                    <ItemTemplate>
                        <telerik:RadMenu ID="RadMenu1" runat="server">
                            <Items>
                                <telerik:RadMenuItem Text="Actions" Selected="false">
                                    <GroupSettings ExpandDirection="Right" />
                                    <Items>
                                        <telerik:RadMenuItem Text="View Process" />
                                        <telerik:RadMenuItem Text="Cancel Task" />
                                        <telerik:RadMenuItem Text="Reassign task" />
                                        <telerik:RadMenuItem Text="Create Linked Work Item" />
                                    </Items>
                                </telerik:RadMenuItem>
                            </Items>
                        </telerik:RadMenu>
                    </ItemTemplate>
                </telerik:GridTemplateColumn>
            </Columns>
        </MasterTableView>
        <ClientSettings Scrolling-UseStaticHeaders="false">
        </ClientSettings>
    </telerik:RadGrid>

    Thanks,
    Shinu
Back to Top