We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

How to change background color for SymbolPalette in WindowForm

How to change background color for SymbolPalette in WindowForm?

I Need to add SymbolPalette On PaletteGroupBar In Code
I Try to Change PaletteGroupBar.GroupBarItems.BackColor and PaletteGroupBar.GroupBarItems.GroupBar.VisualStyle But not Work
Can You Provide Sample Code?

3 Replies

NG Naganathan Ganesh Babu Syncfusion Team October 1, 2015 08:53 AM UTC

Hi rainkuan9,
 
We have created a sample to achieve your requirement. Please refer to the below code example and sample.
 
Code example:
 
[C#]

//setting the visual type
paletteGroupBar1.VisualStyle = Syncfusion.Windows.Forms.VisualStyle.OfficeXP;

//Creating SymbolPalette

Syncfusion.Windows.Forms.Diagram.Rectangle rect = new Syncfusion.Windows.Forms.Diagram.Rectangle(100, 100, 100, 50);

SymbolPalette sym = new SymbolPalette();

sym.Name = "Symbol";

sym.AppendChild(rect);
paletteGroupBar1.AddPalette(sym);

//background color for GroupBarItem
paletteGroupBar1.GroupBarItems[0].Client.BackColor = Color.Wheat;
 
Sample:
 
Sample
 
Regards,
 
Naganathan K G



RA rainkuan9 October 2, 2015 01:34 AM UTC

Thank you Naganathan,

it's really helpful 


SG Shyam G Syncfusion Team October 3, 2015 01:26 AM UTC

Hi rainkuan9,

Please let us know if you need further assistance on this.

Regards,
Shyam G

Loader.
Live Chat Icon For mobile
Up arrow icon