06.02.2010 Added another method for floating the view selector on the right side of the page.
I got a request from “tecrms” that sounded like this:
It’s often harder to think out the question than to actually solve the issue…
This is the default placement of the view-selector:
Here the selector is inserted after the “Settings-menu”:
Here is how it’s done
Add a CEWP below the list view, and add this code (alter the location of the jQuery-scipt as needed)
Use this code for a floating menu on the right side of the page:
33 thoughts on “Move view selector to the left”
Alexander…your rock! Thanks!
Can this be done with the “Site Actions” button too?
Yes it can: Move site actions to the left.
IS there a way to copy, instead of move the view selector? have it on both sides?
I tried to just “clone” the selector, but then the menu is opened in the same selector regardless of which menu you click. I reckon this has to do with the id of the selector not being unique anymore…
It may be possible if you alter the id of the menu, and the function which opens it.
how can I remove the view?
To remove the view selector:
Also look here for a method of hiding only selected view’s:
Hide menu items in list view toolbar and views in view selector.
can we float the menu? I have found that old habbits die hard. I still scroll right looking for the selector. so now I am doing double work looking for this. If the selector can float right, just left of the scrollbar it would always be in view and to the right side of the page.
Yes we can – see updated code.
Floating menu is excellent but I find it buggy if you are in a groupby view. When the user expands a groupby view the selector does not move up (a few pixels) with the menu bar.
Can you give me a screenshot? – i can not see how the expanding of a group can affect the position of the view menu.
I cant seem to locate your email address anywhere on your site. I just must be having a bad day.
But, I did find out that the problem only occurs when IE is not in maximize view.
When you will have paging on list , after click on next page selector will return to right side of the list.
I have made a small update to the code for a floating menu (line 14) to move the paging selector as well. Try this code and let me know if it’s not working.
It is removing the Views picker from the right of the Toolbar, but it is NOT showing the Views picker anywhere else, much less on the left after the Settings drop-down.
Using jquery-1.4.2.min.js, does that make a difference?
Which of the two methods are you using?
Same result with method 2.
View picker disappears, does not show anywhere.
Do you have any other modifications made for that view? Is it WSS 3.0?
No other modifications that I know of, no other CEWPs involved.
WSS 3 for sure, SP 2007.
HTTPS environment with CAC required.
What kind of web browser do you use?
Still stuck with IE 6. Nothing to be done about that.
I have tested it in IE 6.0.2900.5512.xpsp_sp3…
It does Work there, Please specify the version number (Help>About Internet Explorer) of your IE and i will try to test it if i can get hold of the version you have.
Have you tested other scripts from my site with success?
Just got upgraded to IE7 (at last!).
Still does not work.
The View selector disappears entirely.
I am using several scripts from a variety of sites (EndUserSharePoint and PathtoSharePoint for example).
I wsa trying to use this on a web page into which I inserted a list view web part and a CEWP. Did not work.
But when I opened the list directly and edited that page and added a CEWP, this works.
I wonder what the difference would be???
This script is intended to be used in a “native” list or library. If you add a list view webpart to a web part page, the view selector does not exist and therefore cannot be moved.
We originally had the view selector moved to the left, however the content in the calendar and list views have increased to the point where the selector scrolls off the screen.
Since we’re still required to have the view selector on the left, I built on Alexander’s great work and combined the two techniques.
The code below adds toolbar separators, moves the view selector to the left then floats it during horizontal scrolling. The page buttons always float right.
Some of my list have more than 10 views. Is there a way to apply this to the entire list instead of having to build it under every single view??
I have a similar question as to Red’s. How would you go aboout applying the View Selector on the Left Side or Float to the ENTIRE site rather than a single view? This is fantastic, but needs to be able to be applied globally. How would you do that??
You would have to add this code to the master page. I no longer have access to a SP 2007 site and cannot help with the details, sorry.
I figured it out. I exported the CEWP with the code to a web part file and added it to the master page. Works wonderfully!!! Thanks.