Creating top navigation using user control

I want to create a custom user control that will display my own top navigation in my publishing site's master page.  
I know another option is to use sharepoint's own top navigation and then customize it using CSS etc. but I have tried this thing and can't get my head around it. I mean it seems so difficult and very limited in functionality so I am trying to make top navigation
using user control.  
Is there some API that will give me all links in navigation in SharePoint? Like for e.g. SPNavigation which I can call and iterate through all elements including parent or child?  
What are the drawbacks of making top navigation as user control in master page?
Will end user be still be able to use Navigation options in SharePoint Administration?

Hi,
You can customize global navigation at two levels. You can customise the display (how the menu is rendered) but utilize out-of-the-box navigation providers. It'll work if you just want to modify the way navigation is rendered. You can use delegate control
to replace sharepoint control with your own custom user control. In the user control you can access navigation data using SPNavigationProvider(s). However, if you want to customize navigation data - for exmaple, you want to apply some custom logics to show/hide
some navigation link - you need to write your own custom navigation providers.
What I've found, for static menu, managed metadata based navigation will be suffice for most of the scenario - so you don't need to customize the navigation. However for dynamic navigation, you need to write your own navigation control and provider. Reference:
http://blogs.msdn.com/b/gauravbadhan/archive/2013/04/02/creating-a-custom-navigation-for-sharepoint-2010.aspx.
Thanks,
Sohel Rana
http://ranaictiu-technicalblog.blogspot.com

Similar Messages

  • How to create oracle services using grid control

    Hi All,
    I have oracle grid control account my grid control version is 10.2.0.4.0.Can any one please let me know the tab from which I can create Oracle services.
    I know we can create oracle services using DBCA also.When I'm trying to do that way it is giving below error.
    dbca
    DISPLAY not set.
    Set DISPLAY environment variable, then re-run.
    How to set DISPLAY environment variable.
    Thanks,
    Rafi.

    Normally, you set DISPLAY to an IP address with the suffix : and 0.0: the IP address must match a machine able to display X11 windows.
    Example with Linux bash shell:
    export DISPLAY=192.168.0.1:0.0What is your OS version ? What is your shell (bash, ksh, sh, csh) ? How do you connect to the UNIX host ?
    Edited by: P. Forstmann on 8 févr. 2010 09:05

  • Create data guard using grid control 10gR3?

    Has anyone been able to create a data guard of 10g R2 (10.2.0.3 dbs) using Grid Control 10gR3?
    My creation stopped on cloning the standby db step. And i had to finish it manually but i'm just wondering if it has worked for anyone else?

    One step further. I enabled debug tracing for the agent and noticed that the creation of the windows service causes an error.
    -: Thu Sep 27 10:14:53 2007: DEBUG: clone_util.runOradim(): Running oradim to install service for dg2
    -: Thu Sep 27 10:14:53 2007: DEBUG: clone_util.runOradim(): Command: D:\oracle\product\10.2.0\db_1\bin\oradim.exe -NEW -SID dg2
    -: Thu Sep 27 10:14:53 2007: DEBUG: db_common.tempLocFallback(): Test filename: D:\oracle\product\10.2.0\agent10g/sysman/emd/upload/\test_temp_location.2976
    -: Thu Sep 27 10:14:53 2007: DEBUG: db_common.removeFile(): To remove file D:\oracle\product\10.2.0\agent10g/sysman/emd/upload/\test_temp_location.2976
    -: Thu Sep 27 10:14:53 2007: DEBUG: db_common.tempLocFallback(): Tested TEMP location: D:\oracle\product\10.2.0\agent10g/sysman/emd/upload/
    -: Thu Sep 27 10:14:53 2007: DEBUG: clone_util.runOradim(): Output file: D:\oracle\product\10.2.0\agent10g/sysman/emd/upload/\dbclone.2976
    -: Thu Sep 27 10:14:53 2007: ERROR: clone_util.runOradim(): D:\oracle\product\10.2.0\db_1\bin\oradim.exe -NEW -SID dg2:
    The trace refers to file D:\oracle\product\10.2.0\agent10g/sysman/emd/upload/\dbclone.2976 :
    DIM-00019: create service error
    O/S-Error: (OS 1057) The account name is invalid or does not exist, or the password is invalid for the account name specified.
    Although the other steps complete succesfully (using the same credentials), it fails creating the service. Don't know why, yet...

  • How to do configuration to create outbound idoc using message control

    The objective is to create outbound idoc based on some selection criteria using message control approach.The interface will be triggered when there is goods receipt via MIGO transaction.............Now based on the material document number from NAST table i am going to fetch data and do further processing inside the function module i am going to create.later idocs will be created via program RSNASTED.How we do the configuration to set up this whole operation?

    Please go thru:
    1) message control
    2) http://help.sap.com/saphelp_di46c2/helpdata/EN/c8/19878343b111d1896f0000e8322d00/content.htm
    Regards
    Shital

  • Creating Standby database using Cloud Control 12C

    Hi,
    I want to setup Standby database for my existing RAC database, Both standby and PRimary databases are on 11.2.0.3 and we are using "Cloud Control 12C".
    After specifing and testing the Host creddential and Database credentials and choosing the Backup method when I click next I get following error message
    "Username- The Specified user must own the source database oracle server installation."
    I am giving the host credential as oracle, we use single os user "Oracle" for all our installation and administration.
    This is AIX OS and 11.2.0.3 database installation.
    Any help will be appreciated.
    Regards
    Bhushan

    Guys,
    After searching for 2 days on web and raising question on OTN, in the last we resolved the issue. The issue was registering the primary database with correct oracle binaries.
    We have 2 set of binaries Oracle Infrastructure and Oracle RDBMS, The database was register in 12C with Oracle Infrastructure binaries. I changed that and every thing is working soomth.
    regards
    bhushan

  • Top navigation menu items should open in new tab

    In a share point 2013 site, i have created top navigation using term set from managed meta data. some of the menu items navigate the user with in the site whereas some other menu items will navigate to the external sites. My requirement is I want to open
    external links in new tab and internal links in same tab itself.
    Please advise.
    Regards,
    Chaitanya.

    Assuming that internal URL are relative and external urls are absolute, you can use a jQuery script to add target="_blank" attribute to the links.
    This post is my own opinion and does not necessarily reflect the opinion or view of Slalom.

  • I want to implement three level Horizental navigation on the top navigation and menu items are created based on the data available in a SharePoint List.

    Hi All,
    I want to implement three level Horizental navigation on the top navigation and menu items are created based on the data available in a SharePoint List.
    Implement this requirement through customization, how can i start any help
    Thanks

    Hello,
    You can follow these links to get the result that you want. You can get the desired result either using the custom list or a site map. Please make sure when you edit the master page, dont work on the original v4.master. Always make a a copy and then work
    on it.
    This link will show you how get that navigation using a list.
    http://www.bitsofsharepoint.com/BlogPoint/Lists/Posts/Post.aspx?ID=60
    This link will show you how get that navigation using a sitemap.
    http://www.sharepointdiary.com/2012/01/custom-top-navigation-using-sitemap.html
    Please mark as "Answered" if this helped you.
    Thanks,
    norasampang

  • Dynamic Creation of Objects using Tree Control

    I am able to Create Dynamic Objets using List control in
    flex,but not able to create objects using TreeControl,currently iam
    using switch case to do that iam embedding source code please help
    me how to do that
    <?xml version="1.0" encoding="utf-8"?>
    <!--This Application Deals With How to Create Objects
    Dynamically -->
    <mx:Application xmlns:mx="
    http://www.adobe.com/2006/mxml"
    layout="absolute">
    <mx:XML id="treeDP">
    <node label="Controls">
    <node label="Button"/>
    <node label="ComboBox"/>
    <node label="ColorPicker"/>
    <node label="Hslider"/>
    <node label="Vslider"/>
    <node label="Checkbox"/>
    </node>
    </mx:XML>
    <mx:Script>
    <![CDATA[
    import mx.core.UIComponentGlobals;
    import mx.containers.HBox;
    import mx.controls.*;
    import mx.controls.VSlider;
    import mx.controls.Button;
    import mx.controls.Alert;
    import mx.core.UIComponent;
    import mx.controls.Image;
    import mx.managers.DragManager;
    import mx.events.DragEvent;
    import mx.controls.Tree;
    import mx.core.DragSource
    import mx.core.IFlexDisplayObject;
    /*This function accepts the item as on when it is dragged
    from tree Component */
    private function ondragEnter(event:DragEvent) : void
    if (event.dragSource.hasFormat("treeItems"))
    DragManager.acceptDragDrop(Canvas(event.currentTarget));
    DragManager.showFeedback(DragManager.COPY);
    return;
    else{
    DragManager.acceptDragDrop(Canvas(event.currentTarget));
    return;
    /*This Function creates objects as the items are Dragged
    from the TreeComponent
    And Creates Objects as and When They Are Dropped on the
    Container */
    private function ondragDrop(event:DragEvent) : void
    if (event.dragSource.hasFormat("treeItems"))
    var items:Array =event.dragSource.dataForFormat("treeItems")
    as Array;
    for (var i:int = items.length - 1; i >= 0; i--)
    switch(items
    [email protected]())
    case "Button":
    var b:Button=new Button();
    b.x = event.localX;
    b.y = event.localY;
    b.addEventListener(MouseEvent.MOUSE_MOVE,mouseMoveHandler);
    myCanvas.addChild(b);
    break;
    case "ComboBox":
    var cb:ComboBox=new ComboBox();
    myCanvas.addChild(cb);
    cb.x = event.localX;
    cb.y = event.localY;
    cb.addEventListener(MouseEvent.MOUSE_MOVE,mouseMoveHandler);
    break;
    case "ColorPicker":
    var cp:ColorPicker=new ColorPicker();
    myCanvas.addChild(cp);
    cp.x = event.localX;
    cp.y = event.localY;
    cp.addEventListener(MouseEvent.MOUSE_MOVE,mouseMoveHandler);
    break;
    case "Vslider":
    var vs:VSlider=new VSlider();
    myCanvas.addChild(vs);
    vs.x = event.localX;
    vs.y = event.localY;
    vs.addEventListener(MouseEvent.MOUSE_MOVE,mouseMoveHandler);
    break;
    case "Hslider":
    var hs:HSlider=new HSlider();
    myCanvas.addChild(hs);
    hs.x = event.localX;
    hs.y = event.localY;
    hs.addEventListener(MouseEvent.MOUSE_MOVE,mouseMoveHandler);
    break;
    case "Checkbox":
    var check:CheckBox=new CheckBox();
    myCanvas.addChild(check);
    check.x = event.localX;
    check.y = event.localY;
    check.addEventListener(MouseEvent.MOUSE_MOVE,mouseMoveHandler);
    break;
    else {
    var Component:UIComponent =
    event.dragSource.dataForFormat("items") as UIComponent ;
    Component.x = event.localX;
    Component.y = event.localY;
    Component.addEventListener(MouseEvent.MOUSE_MOVE,mouseMoveHandler);
    myCanvas.addChild(Component);
    /*How to move the Objects within the Container */
    public function mouseMoveHandler(event:MouseEvent):void{
    var
    dragInitiator:UIComponent=UIComponent(event.currentTarget);
    var ds:DragSource = new DragSource();
    ds.addData(dragInitiator,"items")
    DragManager.doDrag(dragInitiator, ds, event);
    ]]>
    </mx:Script>
    <mx:Tree dataProvider="{treeDP}" labelField="@label"
    dragEnabled="true" width="313" left="0" bottom="-193" top="0"/>
    <mx:Canvas id="myCanvas" dragEnter="ondragEnter(event)"
    dragDrop="ondragDrop(event)" backgroundColor="#DDDDDD"
    borderStyle="solid" left="321" right="-452" top="0"
    bottom="-194"/>
    </mx:Application>
    iwant to optimize the code in the place of switch case
    TextText

    Assuming your objects are known and what you need are simply
    variable names created by the program, try using objects as
    associative arrays:
    var asArray:Object = new Object();
    for (var n:int = 0; n < 10; n++) {
    asArray["obj" + n] = new WHAT_EVER();

  • Custom field type vs user controls

    hi,
    I saw one example for creating page layouts. In that they are adding the controls to page layout using custom fields . we can use user controls for same right ? when we need custom field types and when we need user controls. 
    Thanks,

    You can use user controls in pagelayouts, but they won't store/retrieve the information from the underlying metadata like the field controls will.
    Paul Stork SharePoint Server MVP
    Principal Architect: Blue Chip Consulting Group
    Blog: http://dontpapanic.com/blog
    Twitter: Follow @pstork
    Please remember to mark your question as "answered" if this solves your problem.

  • How to create a cluster with a User control (.ctl) programatically using VI scripting?

    Solved!
    Go to Solution.

    It seems that you hit the Post button before you had a chance to use the body of the message to give more detail on what you are trying to do.
    Perhaps you can post whatever VI you have so far and also the user control you are trying to use.

  • Hide Top level navigation if user assigned only one role

    Hi,
    I would like to hide the top level navigation if user assigned with only one role.
    I can create role based rule to show desktop using Master rule collection, but is it possible by doing to with role count.
    If user has multiple roles show desktop1 else show desktop2

    not sure if this possible ,you may check feasibility of creating  a application which checks user role count and if role count is = 1 load the Portal url (URL alais) which had TLN iview invisible in the same window else do nothing and load the portal with the desktop which has tln.
    Put the application in framewrk page which has TLN visible.
    create a URL alias and create a desktop -framework page which dont have TLN ,assign this desktop to this URL alias in rule collection set its priority before user conditions check in rule collection so that it has high priority before user or group check in rule collection.
    you can create a poc in sandbox and check if it wiorks?

  • Creating page Navigation without using Dynamic Navigation

    Hi,
    I have a requirement that i need to create few pages where each page will have navigation tabs at the left side and corresponding iviews at the right. Navigation will not  be dynamic but static in nature that means target for the navigation link will not be decided dynamically but will be static. Each tab on the navigation will be linked to a page which will be opened in the same content area. Since there is no dynamic navigation so that's why there is no application present to be used for creating dynamic navigation iview. Please suggest what else can be option to create this sort of page.
    Best Regards,
    Vikash

    Hi,
    If you want your tab on the left instead of the top you need to change the defaultframeworkpage. If some users need to have the navigation on top and some on the left you need to make a custom layout for these users so that only these users have your modified frameworkpage.
    Of course you can not mix tabs on the left and tabs on top. If you want something like that then you`ll need to make a custom html page with tabs on the left pointing to standard portal locations.
    Hope this helps.

  • VB ActiveX User Control fails to install on Windows 8 using IE10 with Code Download Error: (hr = 80070005) Access is denied.

    I have a VB VS2008 (.Net 2.0) ‘pure’ .NET based user control which used to be hosted in Internet Explorer.
    Because that approach is no longer possible in VS2013 (.Net 4.5) I have converted it to an VB ActiveX user control.
    This process involves digitally signing the user control DLL.
    Creating a setup project resulting in a setup.exe and MyUserControl.msi.
    Digitally signing both those components and then producing a cab file (which again is digitally signed).
    IE10 should then be able to install this using an object tag as follows
    <object id="editor" height="100%" width="100%"
     classid="clsid:EA47DB16-9272-4CB3-A800-C369A479396A" codebase="cab\MyUserControl.cab#Version=6,0,11,1" VIEWASTEXT>
    If I use the setup.exe and MyUserControl.msi directly on the client windows 8 machine before starting IE10 then the control is already installed (shows up in Programs and Features) and it works.
    If I don't do this and let IE install the control then it doesn't work.
    What I see is the IE prompt
    This website wants to install the following add-on: 'MyUserControl.cab'
    Clicking on install produces the User Account Control MsgBox
    Do you want to allow the following program to make changes to this computer
    Clicking yes doesn't install the control as expected
    The inf file that I'm using is currently
    [version]
    signature="$CHICAGO$"
    AdvancedINF=2.0
    [Add.Code]
    setup.exe=setup.exe
    MyUserControlSetup.inf=MyUserControlSetup.inf
    MyUserControlSetup.msi=MyUserControlSetup.msi
    [setup.exe]
    file=thiscab
    [MyUserControlSetup.inf]
    file=thiscab
    [MyUserControlSetup.msi]
    file=thiscab
    [Setup Hooks]
    RunSetup=RunSetup
    [Deployment]
    InstallScope=user
    [RunSetup]
    run="%EXTRACT_DIR%\setup.exe"
    I have defined the registry setting ForceCodeDownloadLog
    Examining the temporary internet files location after trying to install using IE10 I can see the following
    *** Code Download Log entry (15 Jan 2015 @ 11:49:18) ***
    Code Download Error: (hr = 80070005) Access is denied.
    ERR: Run Setup Hook: Failed Error Code:(hr) = 80070005, processing: %EXTRACT_DIR%\setup.exe
    LOG: Reporting Code Download Completion: (hr:80070005 (FAILED), CLASSID: ea47db16...,

    The problem here was the cab file.
    Using ProcessMonitor I found that the following entry was generated at the time of failure
    16:48:00.9222751            2920      IEInstal.exe         CreateFile              
    C:\Users\Jim\AppData\Local\Temp\IDC2.tmp\setup.exe             NAME NOT FOUND               Desired Access: Read Attributes, Read
    Control, Synchronize, Dis, Options: Synchronous IO Non-Alert, Non-Directory File, Disallow Exclusive, Attributes: n/a, ShareMode: None, AllocationSize: n/a
    Analysis of the contents of the cab file using PeaZip indicated that it didn't contain setup.exe which confused me for a while as the makecab /f MyUserControlSetup.ddf produced no errors.
    The MyUserControlSetup.ddf contained
    .Set DiskDirectoryTemplate=cab
    .Set CabinetNameTemplate=DocEditor.cab
    MyUserControlSetup.inf
    MyUserControlSetup.msi
    setup.exe
    Using makecab /f MyUserControlSetup.ddf /v3 I saw that the output was being written to 3 'disk' files but only one was present in explorer after it finished.
    So I guessed that the output was for floppy disks and changed MyUserControlSetup.ddf to contain
    .Set MaxDiskSize=CDROM
    .Set DiskDirectoryTemplate=cab
    .Set CabinetNameTemplate=DocEditor.cab
    MyUserControlSetup.inf
    MyUserControlSetup.msi
    setup.exe
    PeaZip now indicated that the cab file contained the 3 files I expected and using that cab in the codebase attribute installed my ActiveX control

  • When playing a home video DVD using DVD Player I tried to use the "Controls, Use current frame as jacket picture" facility to create a printable image but with no success. Can anybody point me in the right direction?

    When playing a home video DVD (created on my Panasonic DVD/Hard Disc recorder)  using the Mac DVD Player, I tried to use the "Controls, Use current frame as jacket picture" facility to create a printable image but with no success. I assume that any file created by this action would be stored somewhere in a common format but cannot find any such file. Can anybody point me in the right direction?

    Hi Sinious,
    Interesting to know about 10.8 and Flash. I'll hold off upgrading until they work together. Currently using 10.6.8 at home and same on the Universtity's computers.
    Haven't verified on Windows but shall do later in the week if I can get access to a Windows machine.
    Both the Flash player and the Projector come up not full screen, and if I leave it that way then things work OK as long as I don't make the video full screen (using the full screen button on the skin).
    However if I make the swf or projector full-screen (by using CMD-F or the menu option) then when I click on the menu item to take me to the page with the video on it, instead of a page with a smallish video and back button I get a black screen with no obvious controls. If I then press Escape I get my normal screen back and I am in the page that should have the video but there is not video and the back button does not work. So something wierd is going on here.
    If I make a file without any videos with a similar navigation structure everyting works ok except that when I go full screen I lose the finger cursor when I roll over my buttons (which is also wierd).

  • How to override the onTouchUp in the user control which can be used to fire the event not only on this user control, but whole application

     I am a new to the C# and WPF. Right now, I want to override onTouchUp event in my user control. Then I can add user control in
    the references for reuse. The problem is each time I want to test this event on the application, the event only fire at area of user control, not whole screen. Anyone has solution for this?

    You cannot just add a UserControl to a window and expect its OnTouchUp method to get invoked when a TouchUp event occurs outside of the user control. That is not how routed events work.
    The OnTouchUp method of the UserControl will only be invoked when a TouchUp event occurs from within the UserControl.
    The event will indeed bubble up to the parent elements of the UserControl and you could for example handle the event in the parent window:
    <Window x:Class="WpfApplicationSlider.MainWindow"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    Title="MainWindow" Height="350" Width="525" TouchUp="Window_TouchUp">
    The OnTouchUp method of the UserControl will however never get invoked when you touch an element outside of the UserControl because an event only travels between the source element and the handler(s). This is how routed events work.
    If you want a "global" TouchUp event handler you should override the OnTouchUp of the top-level
    window:
    public partial class MainWindow : Window
    public MainWindow()
    InitializeComponent();
    protected override void OnTouchUp(TouchEventArgs e)
    base.OnTouchUp(e);
    //do your thing...
    If you want to be able to reuse the functionality across all of your windows in case you have several you could for example create an abstract window class and make all your windows inherit from this one:
    namespace WpfApplication1
    public abstract class BaseWindow : System.Windows.Window
    protected override void OnTouchUp(System.Windows.Input.TouchEventArgs e)
    base.OnTouchUp(e);
    //do your thing...
    MainWindow:
    public partial class MainWindow : BaseWindow
    public MainWindow()
    InitializeComponent();
    <local:BaseWindow x:Class="WpfApplicationSlider.MainWindow"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:WpfApplication1"
    Title="MainWindow" Height="350" Width="525">
    </local:BaseWindow>
    Hope that helps.
    Please remember to mark helpful posts as answer to close your threads and please start a new thread if you have a new question.

Maybe you are looking for

  • Computer not recognizing camera is plugged in (fire wire)

    Help! I need to down load some video from a MiniDV to my computer ASAP -- I'm new at this, got the right fire wire cable but when it's plugged in and turned on, the computer is not registering that there's a camera -- it's a Panasonic miniDV.

  • Can I develop externally in netbeans referencing JCAPS 5.1.2 OTDs?

    I am trying to port some old eGate 4.5.3 code into Sun JCAPS 5.1.2. I have developed a user defined OTD and have been able to unmarshall data successfully inside eDesigner. The original developer had import statements that brought in the old etd defi

  • 'save site as template' missing SP2013

    Hello! I would like to save my webpart page as a template. The problem is that i don't see "save site as template" anywhere on this site. On another site i've created the "save site as template" is visible. What could be the problem? I think i activa

  • Safari Version 4.1.3 (4533.19.4) on emac OS X 10.4.11

    I have trouble with Safari Version 4.1.3 (4533.19.4) going down very regularly (several times a day). I've been using Firefox and that works fine; it has never shut down. Nothing else is a problem: all the other applications work fine. I've tried to

  • Which iTunes9-version should i dl?

    Apple got me confused... Downloading site says: [ ] iTunes9.0 for WindowsXP or Vista [ ] iTunes9.0 for Windows (64bit) Every MS-OS is Windows so which version do i have to dl :s? I'm using Vista 64bit btw Thx