Multi column & Sitemap Datasource

9 posts, 0 answers
  1. Andy Green
    Andy Green avatar
    120 posts
    Member since:
    Jul 2009

    Posted 13 Jul 2010 Link to this post

    Hi

    I have a site map datasource and a RadMenu with security trimming enabled, Now I want to use multiple columns, how can I do this?

    I also need direction, when using a datasource, I have a top level node in a table, with child nodes, I'm trying to display the top nodes (no problem) and the child nodes in a multi column - this is where I'm also having trouble.


    Andy
  2. Andy Green
    Andy Green avatar
    120 posts
    Member since:
    Jul 2009

    Posted 16 Jul 2010 Link to this post

    Any Takers?
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Veronica
    Admin
    Veronica avatar
    1213 posts

    Posted 19 Jul 2010 Link to this post

    Hi Andy Green,

    I've created a sample project as the example Filtering Site-Map Nodes Based on Security Roles in MSDN.
    In my example I use multi-column RadMenu. You can see how to create multi-column RadMenu in this demo.

    I use authentication type "from the Internet" with two users:

    Username: Customer01
    Password: 123456@

    Username: Employee01
    Password: 123456@

    Please take a look at the attached project and see how to filter the RadMenu Items via sitemap nodes based on Security Roles.

    Regards,
    Veronica Milcheva
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  5. Andy Green
    Andy Green avatar
    120 posts
    Member since:
    Jul 2009

    Posted 20 Jul 2010 Link to this post

    Thank you Veronica, but your response isn't quite there ,

    I have security trimming working, and I have read the posts on multi column and can do this, what I need to know is, is it possible to control what appears in the Multi Columns based on Security trimmimg. From what I've read I'd guess no because this looks like its done through templates, can you confiirm.

    If this is not possible, another approach would be to populate the multi colums from a database (and do the security there) but I cant see how to populate the multi columns from a datasource.

    Any more help would be greatly appreciated, I've been stuck with this for days now.

    Andy.

     

     PS - what might help would be a look at the sitemapdatasource for the multi column demo in the example you sent. That might be the missing link.

  6. Veronica
    Admin
    Veronica avatar
    1213 posts

    Posted 23 Jul 2010 Link to this post

    Hello Andy Green,

    I think there was a misunderstanding.

    In my example at first you should not see the "Discounts" menu item as it is only for employees. If you log in as Employee01 you will be able to see the Discounts.

    This could be seen at first:


    This could be seen after you log in as a Employee:


    In my example I control what appears in the Multi Columns based on Security trimmimg. Please take a look at it and feel free to ask me if you have any questions.
     
    The multi-column menu is not done by templates. This feature is controlled through a pair of properties - RepeatColumns and RepeatDirection (either DefaultGroupSettings or per-item GroupSettings). Please take a look at this help topic for more information.

    Regards,
    Veronica Milcheva
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  7. King Wilder
    King Wilder avatar
    240 posts
    Member since:
    Oct 2007

    Posted 21 Oct 2010 Link to this post

    I have a question about this topic, I'm trying to get the "Home" link to show up in the same level as the Products and Services.  Is this possible?

    I need the securitytrimming feature, but I would also like to have the "Home" link included in the menu.

    Thanks,

    King Wilder
  8. Veronica
    Admin
    Veronica avatar
    1213 posts

    Posted 27 Oct 2010 Link to this post

    Hi King,

    To be able to show the "Home" item - you should set the ShowStartingNode property to "true" in the SiteMapDataSource:

    <asp:SiteMapDataSource ID="SiteMapDataSource1" runat="server" ShowStartingNode="true" />

    Please let me know if this was helpful. 

    Regards,
    Veronica Milcheva
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  9. King Wilder
    King Wilder avatar
    240 posts
    Member since:
    Oct 2007

    Posted 28 Oct 2010 Link to this post

    Veronica,

    This doesn't work the way I need, which is to show the menu like this:

    Home | Products | Categories | etc

    In other words, have the Home link on the same level as the others.  If I just set ShowStartingNode to "true", then the menu will only show "Home" as the top level and then Products and Categories as sub levels.

    I also tried creating a subnode in the SiteMap file for Home pointing to the "~/default.aspx" page and it still didn't work.  Nothing showed up.

    I'll just Have Home as a completely separate link elsewhere in the header.

    Thanks,

    King Wilder
  10. Veronica
    Admin
    Veronica avatar
    1213 posts

    Posted 03 Nov 2010 Link to this post

    Hello King Wilder,

    To be able to show the Menu and SubMenuItems on one row - you should set the Flow property of the RadMenu  to "Vertical":

    <telerik:RadMenu ID="RadMenu1" runat="server" DataSourceID="SiteMapDataSource1" Flow="Vertical" >
            </telerik:RadMenu>
            <asp:SiteMapDataSource ID="SiteMapDataSource1" runat="server" ShowStartingNode="true" />

    Hope this helps.

    Greetings,
    Veronica Milcheva
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017