Telerik Forums
UI for ASP.NET AJAX Forum
3 answers
75 views

Hello everyone!

I've got the below RadSiteMap being coded from codebehind (VB). I want to add small icons to the left of each submenu's text however I do not know how. The ImageUrl property apparently does not exist for the RadSiteMap and I cannot think of another way to insert my icons.

Check the attached screenshot to see how my menu looks like and where would I want to add icons. I basically want to add them into the titles and then a different icon to each submenu as well.

Note: My RadMenu is being populated entirely from a database (all of it, parent and childs). If you wish to see the code for a better understanding, I can also leave that in the comments.

Thanks a lot!


Private Function CreateSiteMap(ByVal container As Control, ByVal Id As String) As RadSiteMap
        Try
            System.Diagnostics.Debug.WriteLine("id: " &Id)

            Dim acd As New SiteWeb.AccesDonnees

            'On créer le controle de type RadSiteMap
            Dim SiteMap1 As New RadSiteMap

            'On le configure comme souhaité
            SiteMap1.ID = "SiteMapMenu"
            SiteMap1.DataTextField = "Libelle"
            SiteMap1.DataFieldID = "Identifiant"
            SiteMap1.DataFieldParentID = "Parent"
            SiteMap1.DataValueField = "Libelle"
            SiteMap1.DataNavigateUrlField = "Lienpage"
  
            'This sql receives all the submenus under the current Parent menu
            SiteMap1.DataSource =
            acd.RetournerDataReader("SELECT RTRIM(Identifiant) as Identifiant,RTrim(Libelle) As Libelle,RTrim(Parent) as Parent,RTRIM(Lienpage) as Lienpage,RTRIM(ParentGlobal) As ParentGlobal FROM lobdjetBDD WHERE  NomUser = '" & hf_fonction.Value & "' AND (Parent = '" & Id & "' OR ParentGlobal = '" & Id & "' OR Identifiant = '" & Id & "') Order By Libelle, ChapitreParentGlobal, ChapitreParent,ChapitreEnfant", "EU_BREST")

            SiteMap1.DataBind()

            [.....] I removed this part of the code to make my post smaller on the forums.
 
 container.Controls.Add(SiteMap1)

            Return SiteMap1

        Catch ex As Exception
            Return Nothing
 Exit Function
 End Try
 End Function

 

Valentin Dragnev
Telerik team
 answered on 07 Oct 2022
9 answers
1.9K+ views
Hi. I have erorr "404 Not Found" at the WebResource.axd. Link in background parameter is generates this error (UI for ASP.NET AJAX Q3 2014)
.RadSiteMap.RadSiteMap_rtl .rsmLevel .rsmNodeLines .rsmItem {
padding-right:.83333em;
padding-left:0;
background:url(WebResource.axd?d=f48wGjvl_0dfjPmNr9tLOFvnMRB1CLi8n-kjtv2310YCqz9WudUCfxBHSq03EKuBio5VhswoV9GN6Msark-MNoNqaK7fwka8kcEAy9exFY5jI8t7WdZDzHk_lf7RbccUA8wjhaQPz1iF6FN7gH24LNwpnC6TMkNoLUu3voY_UExZqI460&t=635496800280000000) right -2px no-repeat;}
if i set EnableEmbeddedBaseStylesheet="false" then error does not appear, but sitemap displayed incorrectly.
How i can correct this error ?
Thanks in advance.
Vessy
Telerik team
 answered on 06 Nov 2019
1 answer
38 views

I am implementing the sitemap. When you add a child node, within the parent node it adds an unordered list with the class="rsmList rsmLevel1". I want to edit the unordered list that gets created to hold the child node to append a class to it like:

<ul class="rsmList rsmLevel1 newClass"></ul>

 

However, it seems like I can only edit the class of either the parent <li> or the child <li> node. Is there a way to edit the class of the <ul> that gets grouped with the child node?

Rumen
Telerik team
 answered on 06 Nov 2019
1 answer
91 views

I'm trying to set up radnavigation using a radsitemap to build a list of links in a menu.  

I'm following your demo for radnavigation and server side templates, and I'm getting the same result - a list of links with a bullet in front of each option.

I want to replace the bullet with a custom image, and I've set the node imageurl and now I have both the bullet and the custom image.

See attached image.

How do I remove the bullet and just show the imageurl?

Thanks

                <telerik:NavigationNode Text="Reports" ID="Reports">
                    <ContentTemplate>
                        <div class="column">
                            <h5>MESSAGE ACTIVITY REPORTS</h5>
                            <telerik:RadSiteMap runat="server" ID="RadSiteMap6">
                                <Nodes>
                                    <telerik:RadSiteMapNode Level="0" ImageUrl="images/arrow.png" Text="TOTAL RESULTS SUMMARY" NavigateUrl="~/reports_totalresults.aspx"></telerik:RadSiteMapNode>
                                    <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="DETAILED REPORT" NavigateUrl="~/reports_detailpernumber2.aspx"></telerik:RadSiteMapNode>
                                    <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="USER ACTIVITY" NavigateUrl="~/useractivity.aspx"></telerik:RadSiteMapNode>
                                    <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="TOTAL RESULTS SUMMARY" NavigateUrl="~/reports_totalresults.aspx"></telerik:RadSiteMapNode>
                                    <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="DETAILED REPORT" NavigateUrl="~/reports_detailpernumber2.aspx"></telerik:RadSiteMapNode>
                                    <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="USER ACTIVITY" NavigateUrl="~/useractivity.aspx"></telerik:RadSiteMapNode>
                                    <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="SMS AUTO" NavigateUrl="~/report_smsautoresponder.aspx" />
                               </Nodes>
                            </telerik:RadSiteMap>
                        </div>
                        <div class="column">
                            <h5>PORTAL REPORTS</h5>
                            <telerik:RadSiteMap ID="RadSiteMap1" runat="server">
                                <Nodes>
                                <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="EMAIL COLLECTION" NavigateUrl="~/report_emailcollection2.aspx"></telerik:RadSiteMapNode>
                                <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="SURVEY REPORT" NavigateUrl="~/report_survey.aspx"></telerik:RadSiteMapNode>
                                <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="APPOINTMENT SCHEDULING" NavigateUrl="~/report_appointments3.aspx"></telerik:RadSiteMapNode>
                                <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="APPOINTMETN STATISTICS" Visible="False" ID="report_appointmentsSummary" NavigateUrl="~/report_appointmentsSummary.aspx"></telerik:RadSiteMapNode>
                                <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="REGISTERED CUSTOMERS" NavigateUrl="~/report_ServiceDetails.aspx"></telerik:RadSiteMapNode>
                                <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="OVERDUE REPORT" NavigateUrl="~/report_overdue.aspx"></telerik:RadSiteMapNode>
                                <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="UPDATED RECORDS" NavigateUrl="~/report_UpdateRecords.aspx"></telerik:RadSiteMapNode>
                                <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="CLICK REPORT" NavigateUrl="~/report_redir.aspx"></telerik:RadSiteMapNode>
                                <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="SEARCH PINS" NavigateUrl="~/report_pins.aspx"></telerik:RadSiteMapNode>
                                <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="SMS ACTIVITY" NavigateUrl="~/reports_smsdetail.aspx" />
                                </Nodes> 
                                </telerik:RadSiteMap>
                        </div>
                        <div class="column">
                            <h5>ROI REPORTS</h5>
                            <telerik:RadSiteMap ID="RadSiteMap2" runat="server">
                                <Nodes>
                                    <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="ROI REPORT" NavigateUrl="~/report_roi2.aspx" />
                                    <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="CONQUEST REPORT" NavigateUrl="~/report_ph.aspx"></telerik:RadSiteMapNode>
                                    <telerik:RadSiteMapNode ImageUrl="images/arrow.png" Text="SUCCESS REPORT" NavigateUrl="~/report_success.aspx"></telerik:RadSiteMapNode>
                                </Nodes> 
                                </telerik:RadSiteMap>
                        </div>
                        <div class="column">
                            <div id="qr" style="display:inline-block;width:75px;height:75px;align:center;vertical-align:middle;" >
                                <img src="images/placeholder.png" style="height:75px;width:75px;">
                            </div>
                            <div style="display:inline-block;vertical-align:middle;">
                                <h5>TOTAL RESULTS SUMMARY</h5>
                            </div>
                            <div style="width:400px;overflow-wrap:break-word;">
                                Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod<br />
                                tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, <br />
                                quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo <br />
                                consequat. 
                                <br /><br />
                                Duis aute irure dolor in reprehenderit in voluptate velit esse <br />
                                cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non <br/>
                                proident, sunt in culpa qui officia deserunt mollit anim id est laborum.<br />
                            </div>
                        </div>
                    </ContentTemplate>
                </telerik:NavigationNode>

Bill
Top achievements
Rank 1
 answered on 04 Oct 2019
4 answers
79 views

Hi,

 

Why is the following only working with Flow and not with List:

                   <telerik:SiteMapLevelSetting Level="1" ListLayout-RepeatDirection="Vertical" Layout="List">
                               <NodeTemplate>
                            <asp:HyperLink ID="HyperLink1" CssClass="rsmlink" NavigateUrl='<%# DataBinder.Eval(Container.DataItem, "linkto") %>' Text='<%# DataBinder.Eval(Container.DataItem, "description") %>' runat="server"></asp:HyperLink>
                    </NodeTemplate>
                             <SeparatorTemplate><hr /></SeparatorTemplate>
                         </telerik:SiteMapLevelSetting>

 

I need to create separators between the items...

 

Marc

Fit2Page
Top achievements
Rank 2
Iron
Iron
Iron
 answered on 19 Jun 2019
3 answers
61 views

I have been looking for a bit, and have not found the answer.  I feel like I just might have overlooked it.  

How does the RadSiteMap control know where to break the items into the next column.  I am using one of your demos (loading it with XML from code behind - which doesn't work straight out of the ZIP btw).  The menu item is set up with a RadSiteMap control with three columns.  I can add and remove items from each of the groups, and it will continue to break in the same place.  There are two groups under the first column, and one group under each of the others.  How does it know, or - more importantly - how do I tell it when to break to another column?

Brian
Top achievements
Rank 1
 answered on 13 Aug 2018
2 answers
44 views

I'm developing a menu using RadMenu and RadSiteMap.  I'm getting the nodes by using SiteMapProviders.  Everything is working, but I have to add a 4th level at certain nodes and this causes the menu to look untidy and the styling changes.

So I was thinking of having the 4th level pop out when you hover over its parent node like a tooltip.  Can you use the Tooltip control with SiteMap?  If yes, how do link to just the 3rd level nodes which has child nodes?  I can't find any examples on the forum or demos.

Fanie
Top achievements
Rank 1
 answered on 29 Mar 2018
1 answer
74 views

Hi there,

I would like to change a couple of things regarding styling to the RadSiteMap (see attachment)

1. Remove horizontal line
I want to remove the horizontal lines, like beneath the 'Auxiliary equipment' text and 'Drivetrain' text.

2. Remove indent level
Is there a way to remove the indents before a level (like before the bullets)?

3. Add empty line last level
I want to create extra space between the 2 levels (like extra space between 'Weigh scale hand pallet trucks' and 'Drivetrain')

I hope somebody is able to assist.

Regards,

Marcel

Rumen
Telerik team
 answered on 01 Mar 2017
1 answer
74 views
I'm trying to change the font size larger in my site map, but not having much luck. I've attached a screen shot of what I have now. I want "Cost", "DP", "PCIP", etc to have a larger font than the links under "Cost", like default.aspx, login.aspx, etc. "Cost" folder is a folder under the root.
Aneliya Petkova
Telerik team
 answered on 12 Jun 2015
0 answers
63 views
Greetings Developers, im working with this structure, the problem is that i cannot hide a node: - i'm looking a control for the node, i want to display the menuNode for some authentications and not for others
 1.-
Not able to add an ID, tells me "object its not in the current context"
i was looking for  this solution and to  implement jquery .hide(), but
doesn't work
"<telerik:RadSiteMapNode 
NavigateUrl="../Honorarios/GenerarPrevio.aspx?sbmH=GP" Text="Generar
Previo" ClientIDMode="AutoID" runat="server">"  <div class="Menu">
                    <div id="MegaDropDown">
                       
<telerik:RadMenu runat="server" ID="RadMenu1" Skin="Sitefinity"
OnClientItemOpened="itemOpened" EnableRoundedCorners="true"
ClickToOpen="True"
                            Width="895" Height="48" EnableShadows="true" Font-Underline="True" Style="top: 0px; left: 0px">
                            <Items>
                                <telerik:RadMenuItem Text="Honorarios" Width="106px" runat="server">
                                    <Items>
                                        <telerik:RadMenuItem CssClass="Honorarios" Width="880" runat="server">
                                            <ItemTemplate>
                                                <!--Submenu-->
                                                <div id="CatWrapper" class="Wrapper" runat="server" >
                                                   
<telerik:RadSiteMap ID="RadSiteMap1" runat="server"
EnableTextHTMLEncoding="true" BackColor="Red" i >
                                                        <LevelSettings>
                                                            <telerik:SiteMapLevelSetting Level="0">
                                                                <ListLayout RepeatColumns="2" />
                                                            </telerik:SiteMapLevelSetting>
                                                        </LevelSettings>
                                                       <Nodes>
                                                           
<telerik:RadSiteMapNode 
NavigateUrl="../Honorarios/GenerarPrevio.aspx?sbmH=GP" Text="Generar
Previo" ClientIDMode="AutoID" runat="server">
                                                            </telerik:RadSiteMapNode>
                                                           
<telerik:RadSiteMapNode
NavigateUrl="../Honorarios/SegFol.aspx?sbmH=SF" Text="Seguimiento de
Folios" >
                                                            </telerik:RadSiteMapNode>
                                                                </Nodes>
                                                    </telerik:RadSiteMap>
                                                </div>
                                            </ItemTemplate>
                                        </telerik:RadMenuItem>
                                    </Items>
                                </telerik:RadMenuItem> i hope you can help me, thanks & sorry for my bad grammar.
mauricio
Top achievements
Rank 1
 asked on 05 May 2015
Narrow your results
Selected tags
Tags
+? more
Top users last month
horváth
Top achievements
Rank 2
Iron
Iron
Steve
Top achievements
Rank 2
Iron
Erkki
Top achievements
Rank 1
Iron
Mark
Top achievements
Rank 2
Iron
Iron
Veteran
Jakub
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
horváth
Top achievements
Rank 2
Iron
Iron
Steve
Top achievements
Rank 2
Iron
Erkki
Top achievements
Rank 1
Iron
Mark
Top achievements
Rank 2
Iron
Iron
Veteran
Jakub
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?