Problem with writing the valueTreeState into an xml file

I can’t see anything obviously wrong with that, so two dumb questions first. Are you sure you’re looking at the correct file on the disk? Is there any other code resetting values to default and writing to file before you inspect it?

Btw, if you haven’t seen it Reuben mentions a neat way of storing a reference to your parameter before you add it to the layout. Then you could just do k = detuneParamRef->get().