Welcome to Office Zealot Sign in | Join | Help

MOSS 2007 Web Part Chrome Types

After you drag and drop a web part onto a SharePoint site, you have the ability to modify the look and feel via the shared web part properties.  One such property is Chrome Type.  It allows you to set the appearance of a specific web part to have Title Only, Border Only, Title and Border, or None.  The default setting is Title Only.  What if you want to change the default for all your web parts?

First, some educational details.  The Chrome Type is actually associated with a web part zone (or section of a SharePoint site).  It determines the default presentation for all web parts in the zone.  Via shared web part properties, the default can be overridden for a specific web part.  So, where are the web part zone defaults stored?  These are located in the site templates directory (../program files/common files/Microsoft shared/web server extensions/12/templates/sitetemplates/../XML) and are in the onet.xml file.  You'll see an attribute called 'ChromeType' for each zone in the site template.  There are about a dozen site templates.  So, to change the default for all sites that use a particular site template change the onet.xml file.

The available values for ChromeType are here: http://msdn2.microsoft.com/en-us/library/system.web.ui.webcontrols.webparts.partchrometype.aspx.

Published Thursday, January 11, 2007 1:22 PM by Mauro

Comments

Tuesday, January 16, 2007 1:51 PM by kentek

# re: MOSS 2007 Web Part Chrome Types

Michael,

I'm a newbie to MOS 2007 and not a programmer. Just a lowly configurator.

I have upgraded my Sharepoint server with new MOSS 2007 Trial version. Farm is set up, and I made it through several pages of your excellent Chrome tutorial. I successfully created a web site.

I needed to do an iisreset /noforce to get it to come up. I'm very pleased to get this far.

I originally worked with your Chrome tutorial when I had WSS 2.0 Beta 3 installed.  I got a bit futher on that attempt but version isses cropped up near the end of my CSS venture and I gave up.

So, now with MOSS 2007 release I'm back at it working with your Chrome tutorial.

As you are aware with the RTM version of MOSS 2007 many of the CSS file names and menu layouts have changed.

Is there any chance that you may re-visit your Chrome tutorial and do an update?

I will continue to muddle through the tutorial but expect that I will be successful in breaking my MOSS install. I always am.

I know you SPS.NET guys are really busy. Good for you.

Tuesday, January 16, 2007 2:24 PM by bostonmusicdave

# re: MOSS 2007 Web Part Chrome Types

We've actually tried this and not been successful.  Important to note that this does not seem to work on the RTM code.  We've worked with folks from microsoft and noone seems to be able to make this happen.

Thursday, September 13, 2007 2:41 PM by akawa

# re: MOSS 2007 Web Part Chrome Types

This works great!  Thanks Mauro!  We did an in-place upgrade and noticed all of our web parts had a border and title around it.  It would have been huge undertaking to manually change all web parts on all pages to have the desired chrome type.  Instead, we left the chrome type of default on all web parts and edited our web part zones in our page layout so that the web part zone had the desired chrome type.  The chrome type in the zone is now the chrome type that is being used in each web part.

Thanks again,

Sunday, August 03, 2008 11:45 by web part zone contains web part

# web part zone contains web part

Anonymous comments are disabled