SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm working on a web part that thematically makes sense to have the XSL Link property in a custom category I created Visual Settings that provides new WPProperties for things like the CSS page and which Javascript file to attach to the web part. In this sense, it makes sense for us to move that property out of Miscellanous and into this custom category.

I thought it would be just as simple as writting over the property in my code-behind, but that doesn't seem to be the case (it breaks the webpart when I do that). Any advice?

share|improve this question

If I understand you correctly you're inheriting from a Web Part which has XSLLink in the Category Miscellanous and you want to move it to Visual Settings.

You should be able to do that like this:

[WebBrowsable(true), Personalizable(PersonalizationScope.Shared)]
[WebDisplayName("XSL Link")]
[WebDescription("Link to XSLT")]
[Category("Visual Settings")]
public new string XSLLink
  get { return base.XSLLink; }
  set { base.XSLLink= value; }
share|improve this answer
The line in the .webpart file has no influence. Is your new propery the exact same spelling and casing as the old? – Per Jakobsen Mar 28 '12 at 15:24
Yes, and in fact if you change one it changes the other. It was strange to see me delete the value in the original XSLLink property only to have the value deleted in the new property! – EHorodyski Mar 28 '12 at 17:00

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.