How to replace a node with another node

Hi,

I have the following requirement.
i have a node in the diagram when i right click i want to replace the node with another node to the same location
How can i do that.....

If you want to completely change the node’s appearance, use a DataTemplateDictionary and change the node data’s Category. Each Category string value should be an entry in the Diagram.NodeTemplateDictionary.

Several of the samples make use of DataTemplateDictionarys to have different appearances for node data depending on the value of the node data Category property. I don’t recall off-hand whether any samples let the user modify the Category property, but there isn’t any reason why not. Changing the category will remove the old Node and reconstruct a new one.