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

Error adding symbol in a Palette


If I try to add a symbol in a Palette I've got the next error (see video).

SymbolPalette paletteCur = symbolPaletteGroupBar.CurrentSymbolPalette;
                Group mysymbolmdl = new Group();              
                if (this.diagram1.Model.Nodes.Count != 0)
                    int inicio;
                    mysymbolmdl.AppendChildren(this.diagram1.Model.Nodes, out inicio);// .AppendChild(nodeSeleccionado);

Attachment: Video_1560759746_f02ccd2d.zip

3 Replies

RT Ramya Thirugnanam Syncfusion Team June 17, 2019 10:39 AM UTC

Hi Blanca,  
We have analyzed the provided query. It seems that grouping is applied to  Diagram’s nodes directly while adding diagram nodes to the SymbolPalette. This is the root cause of the reported issue. We suggest you create the group node by cloning the diagram’s object while adding diagram nodes to the SymbolPalette. Please refer to the below code example.  
Code example:  
Group group =new Group();  
int indee;  
//Clone the diagram object to group...  
group.AppendChildren(this.diagram1.Model.Nodes.Clone() as NodeCollection, out indee);  
Ramya T 

BC Blanca Calderon June 17, 2019 10:52 AM UTC

Thank you, I think that works properly.

RT Ramya Thirugnanam Syncfusion Team June 18, 2019 05:22 AM UTC

Hi Blanca,  
Thanks for your update. 
Ramya T

Live Chat Icon For mobile
Up arrow icon