woensdag 19 maart 2008

Migration - QuickLaunch

It has been a long time ago since i made my last post, but that's because of my current project, there's a lot of pressure on it at the moment.

At the moment i am busy on migrating a SP2003 environment to a SP2007. Due to the customers wishes, this is a very time consuming project. I decided to write a nice tool to help me migrate all the webparts, it's data and the navigation, since we used Tzunami for the content migration. It helped me in some way, but i can say: it isnt worth it's money. 12000 Euro for a product that has a lot of bugs and misses a lot of functionality.

well, let me go further on the main subject ;) I was asked if it was possible to maintain all links in the quicklaunch and in the same order. At first, it didnt look too good for me: The object model of sharepoint 2003 didnt allow me to gather information about the quicklaunch menu.

So I decided to write a query to get the navigation information out of the database and stored into an xml file:




In SP2003, the order of Documents, PictureLibrary, Lists are in an order that is always the samen (when nog changed). In SP2007, the order depends on the order of creating doclibs and lists.

For example, when a list is created first and after that, a doclib is created, the menu "List" will be displayed above "Document Library" (or whatever its name is ;))

This problem is tackled with the following code:
- make all lists and doclibs invisible in the quicklaunchmenu:




afther that,

use this function to add items:



use the following function to add the items to the quicklaunch: they are added to the right subMenu


And use this function to put the subMenu items in the right order:

Geen opmerkingen: