Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
675
can you overlap styleset?
posted

Hi, There

I have a question about styleset. Can you apply multiple styleset, overlapping one on top of the other, to the same control? We are running into this scenario where we need to allow user to configure the display of a grid. User can choose to alternate row color, to use different color scheme, and different fonts. If we can only use one styleset for the grid, we'll have to create one styleset for each combination of alternate color/color scheme/font size. If we can overlap the styleset, then we only need to create one styleset for alternate color on/off, one for each color scheme, and one for each font size, and pick and combine them togather. 

From the documentation it doesn't seem this is possible, is there any other way to get around this? or if this function possible in future release?

Thanks.

 

Richard Zhu

Parents
No Data
Reply
  • 469350
    Verified Answer
    Offline posted

    Hi Richard,

    No, you cannot apply multiple styleset to the same control.

    You can modify the StyleSet at run-time, but it's a bit tricky. I've posted a couple of simple samples that demonstrate this, such as this one: Change font at runtime - Infragistics Forums

    Also, Stylesets do support a form of inheritance. If you are editing a Style Library in AppStylist, you can set one StyleSet to be BasedOn another one. But this is not something you can realistically do in code, you have to modify the style library itself. So I don't think that helps you in this case.

Children
No Data