Drag and drop component with a synthesiser

Hello everyone, I would like to create a drum pad vst, the user will drop the file directly on the button, so I used a text button wich inherit from drag and drop class, This part works, The probleme : I don’t know how can I connect my synthesiser to this button to change the sample when a new is loaded. Thank you and good day !