Hi All,
I have a paletteset which contains multiple palettes. How can I set one of the palette on top through code?
It is something like set current tab in tab control
Any hints?
Thanks
Regards,
Yaqi
Solved! Go to Solution.
Solved by norman.yuan. Go to Solution.
Palette contained in a PaletteSet is indexed by its order being added into the paletteSet. If you know the index of the pallete, you can call PaletteSet.Activate(index) to activate the palette, or you can loop the PaletteSet with palette name (Palette has a name when being added into PaletteSet):
For i As Integer=0 To myPaletteSet.Count-1
Dim p As Palette=myPaletteSet(i)
If p.Name.ToUpper()="SOMENAME" THEN
myPalleteSet.Activate(i)
Exit For
End If
Next