Friday, December 7, 2012

Change your WebParts group displayed category

By default when creating a new SP2010 WebPart or VisualWebPart it gets added to the 'Custom' group category.
 
 
There is two ways of changing this:
 
The first is by using the UI:
  1. Click Site Actions then Site Settings
    .
  2. Under the Galleries group click the Web parts link.
  3. Find and open the webpart in questions settings.
  4. In the Group section, under the Specify your own value option, type in a group name.
 
The second is via code:
 
In your VS solution, under the relevant project, expand your WebPart to expose the Elements.xml file.


You need to change the value of the Group tag under the Property element that sits under root\Elements\Module\File\



<Property Name="Group" Value="Custom" />

Result:


No comments:

Post a Comment