I'm using a CombinedDomainXYPlot with 4 charts and I'd like to remove one of the chart and replace it by another when I click on a button. I thought I could do it by using the add and remove method, but it doesn't work, I'm getting an error

Thanks for helping.
Edit : found, I have just noticed a mistake in my code.