@Anonymous wrote:
I'm OK with WPF - going this way.
what is inside FillData?
how specific command should look? As I suppose above - just regular elements with handle click and run declared command in document context?
In the very early versions of the AutoCAD API (pre-2008 or -2009, I believe), the PaletteSet class was sealed, and you could not derive specializations from it. Then the ribbon and floating Layer properties palette came along, and Autodesk unsealed the PaletteSet class and made some of its methods/properties virtual so they can overridden in derived types. The ribbon is hosted by a class derived from PaletteSet, and all other managed PaletteSets that come in the box (like the Layer Palette) use specialized derived types that allow much greater control over the PaletteSet.
Unlike the examples given by both @_gile@ and @Anonymous_Becke, I think it is better in the long-term to follow that same pattern and derive a class from the PaletteSet and create an instance of that rather than the base PaletteSet class. That gives you a way to initialize it internally in the constructor, so that it has no external dependence on the command that shows it. The command that shows your PaletteSet should do nothing other than create an instance of the PaletteSet and call it's Visible method. The rest should be handled internally by the PaletteSet (in a derived type, just place all of the code that initializes it in the constructor). You don't want a UI component like a PaletteSet to have a dependence on a command method, or any other code for that matter, because you may want/need to create and show the PaletteSet from some other place or context, and you would need to replicate all of the Initialization code that is done in the commands shown in the examples from @_gile and @Juergen_Becker in any other place where you need to create/show the PaletteSet.
Just as we don't (and should not) use the System.Windows.Forms.Form class directly (Visual Studio creates a class derived from it when you add a Windows Form to your project), we also shouldn't do that with the PaletteSet either.
You can see a very basic example of using a PaletteSet by deriving a class from it in >this post<, which also shows how to run code in the document context from the click handler of a Button or other control on a PaletteSet.