How recording Program changes informations in a MIDI patch please ?

zined's icon

HI everybody

In the patch below it's possible recording a MIDI performance played from a MIDI keyboard for instance.
[pgmout] object alows setting Program Change. But how is it possible recording those Program Change informations ?
Nicolas gave me a cordial idea and advice : using [midiformat] object ; but I failed...... Could you help me please ;-)

Max Patch
Copy patch and select New From Clipboard in Max.

Thanks so much.
zined