It is possible to fill input text from the change event of a select2

I am creating a veterinary software, I am looking for the way to fill several input text when selecting an option from a select2. It is possible to do it, how is it done?
Thank you

Yes. Assign an event handler for the change or change.select2 event to the select element. In your event handler, you can then modify your other input fields.

john thanks for your help.