Changing the ID of an element in an xrc

Thanks Robin,

I will definitely try out what you propose.

A workaround that also seems to work, but which is not as flexible as what you’re proposing is:

#Get the Button Control
button =self.dlg.FindWindowById(xrc.XRCID(‘newButton’))

#Change the button ID
button.Id = wx.NewId()

Of course I need to keep track of the new generated ID’s that way

Best regards,
Tom.