.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

How to use Page/Content Field data in a Navigation - how to include images in a navigation?

Posted By:      Posted Date: September 21, 2010    Points: 0   Category :SharePoint


I look for a hint on how to accomplish the following:

I create a Internet-type of Site based on the Publishing Infrastructure/Features. The site is structured by subsites that are all based on same Masterpages and PageLayouts. In the PageLayouts there are the common fields like Title, Page Content, Page Image. And exactly the last one "Page Image" should appear in the navigation.

Searching the web pointed me to creating a custom PortalSiteMapProvider. In the GetChildNodes I figured out how to get the actual Url to the "Page Image" of a Node in the Sitemap. 

But here I'm stuck. How to I get this information (the image url) delivered to a menu control to actually draw an img src=...?The build-in Nodes don't seem to support such an additional property. And the build-in menu controls (asp:menu, sharepoint:aspmenu) neither.

What do I need to create to make use of the ImageUrl? A custom Web part? or ... ?

Any hints welcome


Thank you


Long time WinXP user, skipped Vista and starting to like 7

View Complete Post

More Related Resource Links

how to increase Performance onloading page and navigation of records ?? Help








this is my aspx and cs code , let me know whether it is correct or not??

onload and performance on navigation of record show be good.

Plz help me

<CR:CrystalReportViewer ID="CrystalReportViewer1" runat="server" AutoDataBind="True"

                DisplayGroupTree="False" ReuseParameterValuesOnRefresh="true" HasToggleGroupTreeButton="False" Height="1039px" ReportSourceID="CrystalReportSource1"

                Width="901px" />

            <CR:CrystalReportSource ID="CrystalReportSource1" runat="

Extreme ASP.NET: Page Navigation


In my childhood I spent several weeks a year in Holland with my extended family. As a young American boy I was fascinated with the electric Dutch trains, something we didn't see in my hometown of Dallas, Texas.

Rob Howard

MSDN Magazine October 2005

How to Customize Navigation for a Wiki Page



I've created a wiki library with 10+ wiki pages. I want users to be able to move from page to page on the Quick Launch navigation bar without having to go back to the wiki library home. Is this possible? I see the "Recent Changes" quick launch navigation feature that seems to accompany all wiki pages in a wiki library. Can I add another component similar to the "recent changes" feature that simply lists all of the pages in the wiki library?



Page to page navigation from listbox menu?

I am wondering if anyone can share with good sample on how to create menu populated in a listbox from xml and have page to page navigation between xaml pages. I need to have a unique Uri link associated with each item in the listbox. Any advice is highly appreciated. Thank you in advance,

web page navigation

Hiii Coders, I m trying to navigate to web page using html: <a href="">mywebpage</a>. It works fine but openede the destined page insame tab of my browser. But i want that it should opened the destined page in other tab of browser leaving the  current tab ineffected. How can i get it? plz provide some code snippets? thanx and regards  

Page navigation in a frame throws an exception

I created a very simple WPF project that exhibits the following error. I have no idea how to get of this error. System.Windows.Data Error: 4 : Cannot find source for binding with reference 'RelativeSource FindAncestor, AncestorType='System.Windows.Controls.Menu', AncestorLevel='1''. BindingExpression:Path=TemplatedParent; DataItem=null; target element is 'MenuItem' (Name=''); target property is 'CommandTarget' (type 'IInputElement') Steps to reproduce:1. Create a WPF Application project in Visual Studio 2008 (Windows 7)2. Create Page1.xaml <Page x:Class="WpfApplication1.Page1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="Page1"> <TextBlock> <Hyperlink NavigateUri="Page2.xaml">Page 2</Hyperlink> </TextBlock> </Page> 3. Create Page2.xaml <Page x:Class="WpfApplication1.Page2" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="Page2"> <TextBlock> <Hyperlink NavigateUri="Page1.xaml">Page 1</Hyperlink> </TextBlock> </Page> 4. Add a frame in Window1.xaml <Window x:Class="WpfAppli

Proper way to do page navigation.

I'm creating a WPF desktop application. I have a MainWindow. Inside the MainWindow I currently have a Frame that will host all of my pages. I am using myFrame.Navigate(PageToNavigateTo) in my CommandBinding Executed method when clicking a radio button. There are 8 radio buttons, one for each page. I am hiding the navigate next/back with this: NavigationUIVisibility="Hidden" This all works well and I can change pages when clicking the radio buttons. How can I bind content inside my frame's pages to elements on my MainWindow that are outside the frame? For example, lets say on page8 is loaded in myFrame . If I have a TextBox on that page and type some text in it. I want a label sitting outside of the frame on my MainWindow to update with that text. How can I do this? I try setting the DataContext of the frame and that doesn't work. I have a sample app working up to this point and could post it somewhere if that would help. Thanks in advance.

Data Navigation in WPF

I've seen many samples using just a few simple buttons slapped on a wpf form for Data Navigation:               <Button Name="first" Content="First" Click="GoToFirst "/>             <Button Name="previous" Content="Previous"  Click="GoToPrevious" Grid.Column="1"/>             <Button Name="next" Content="Next" Click="GoToNext" Grid.Column="2"/>             <Button Name="last" Content="Last" Click="GoToLast" Grid.Column="3"/>   Or using buttons to mimic the old style winforms data navigation strip like in this blog entry http://blogs.msdn.com/b/vsdata/archive/2009/06/22/build-your-own-navigation-bar-for-data-navigation-in-wpf.aspx   I find the look of these approaches to be a bit cheesy. One could add some pictures to the buttons to make it a little more "pretty" but this is basically the approach  i was using back in the 90s developing apps with vb4/vb5.  What design metaphors are developers using today for real world apps for paying customers?  

How to change the value of a foreign key field/navigation property?

How can I change the value of a foreign key field?  E.g. in the Product list view instead of the value of the field Supplier.CompanyName I want to display the Supplier.Region. I searched my whole code to get a clue, googled for "change navigation property" and looked in the docs but unfortunately I did not find any hint. If you know where to find the answer, please let me know too the source of your knowledge!          

adding quicklinks/tree navigation to main search page (search 2010 express)

Hi Just installed Search Server 2010 Express (full version). On the previous version you could add the top link bar to the search page to easily allow you to browse to other sections i.e contacts. With 2010 I cannot seem to add any kind of navigation away from this main page (default.aspx). Using Designer it will not allow me to edit the top bar, quick launch, tree view and top link bar have been enabled with links however they do not show up on the main search page. can someone help ?

How to add Metada Navigation (taxonomy tree and key filter) to new webpart page

Hi all, can anyone tell me if it's possible, and how, to use a Metada Navigation control (taxonomy tree and key filter) in a webpart page created like there are in the list pages. I was looking to add such a control and connect it to 2 listview webparts. Thanks in advance!  

Web Part Page doesn't show current navigation

Hi! I'm having a problem with the navigation of web part page in Sharepoint 2010. For starters I need to say that I am a web designer and learning to brand Sharepoint 2010 wich means I'm not that tech-savvy so bear with me. We have created an intranet publishing site with Sharepoint 2010 and I have designed a custom master page with styles through Visual Studio 2010. The intranet site looks fine with the new design and I got navigation working with fly out menus, semantic subpages etc. The problem is: when I create a normal page the current sub-navigation is shown and it even shows my created web part page and all is fine, but once I go to this web part page, the left/sub-navigation disappears and I have no idea how to bring it back. The web part page uses the same master file as every other page. Everything with the the layout stays the same as my masterpage, except for the menu wich disappear so I thought it might be some property missing on the sub-navigation. Or do I need to edit something in the web part page layout in the gallery?: Master Page Gallery > BlankWebPartPage.aspx If so can I do it from Visual Studio? Here is the code for the left navigation menu: <!-- styles needed to have left nav to the left of the main area --> <div id="s4-leftpanel" class="s4-notdlg"> <!-- The quick launch bar / left navigation

Cannot add content to object of type 'System.Windows.Navigation.NavigationWindow'

Hello, i'm trying to add content to a custom class inherited from System.Windows.Navigation.NavigationWindow but i receive the following error: Cannot add content to object of type 'System.Windows.Navigation.NavigationWindow' This is the XAML of my Window: <NavigationWindow x:Class="Obolus.Windows.MainWindow"     xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"     xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"     Title="..."     Style="{StaticResource MainWindowStyle}" ContentRendered="NavigationWindow_ContentRendered" >     <Grid></Grid>     </NavigationWindow> what i want is drawing shapes in this window, which will act as container and background for a lot of pages inside. It will be a classic Wizard. In .Net Windows Forms i override the OnPaint method of any control, and i draw all the things programatically. I don't know hot to do it in WPF. ¿Adding shape contents to the window? ¿overriding OnContentRendered? ¿any idea? Thanks in advance, Best regards, Raúl Truco,  

Is there any way to populate an InfoPath form field with the data from the site content type column?


I have a Form library with a form template.

The templat has a field "Office name" which should not be a fixed list of values, but a dynamical list, feeded from a different type of form. I'm a novice with InfoPath - Sharepoint and I want to find out, how can I can give users a possibility to create and maintain a list of offices and also have this list as a selection list inside main library form - ALL inside one library, if possible.

I assumed that if I publish main form (Itinerary) as a library template form and lookup form (OfficeInfo) as a SiteContent, I should be able somehow to connect to siteContent column and it's information. But I cannot see how - Site Content Gallery is not appering as a Connection item.

Can I use SiteConenct for this purpose or there are other ways to create end-user lookup lists?

Thank you!


how to insert data into database from content page?


Please help me to insert data to database from a content page of a master page. My code is working fine when i use my code without master page but with content page of master page i dnt knw what goes wrong. Help me on this please.

thank you

Navigation from window to page in wpf using c#

I want to navigate from window.xaml to page.xaml.Please help me....

How to persist data binding during pagefunction navigation?


In my example below I have a "MainWindow" with 2 text boxes showing data from a Class1 object.

On loading the "MainWindow" I create a new Class1 object, "myObj", and assign this object to the DataContext of the "MainWindow" grid.

The TextBox Text properties were bound in the XAML.

The new data is displayed correctly on the page.

I click the "Next" button to navigate to a PageFunction which displays a message and a "Back" button.

On clicking the "Back" button the click event executes an OnReturn.

Back in the "MainWindow" the OnReturn event handler displays a message indicating that the event was executed.


When the "MainWindow" is displayed the fields are blank - what is the recommended method for persisting the data binding definitions?

A solution that I tried (reflected in my code below under the heading "Page function with persisted data"):

1) Add a Public Property in the PageFunction to receive the Class1 object ("myObj" to be persisted)
2) In the PageFunction "Back" button click event, return the object in the OnReturn statement.
3) In the "MainWindow"'s return event handler, assign the returned object to the "myObj".

This alone does

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend