Change node template

I want to change the nodetemplate against same key and the same should be reflected in designer . what shud i do ?

So you have an existing Node in a Diagram, and you want to keep the node but replace its template? You can either call Model.setCategoryForNodeData or you can set Part.category. Within a transaction, of course.