Your comments

Yes, the same way. It is option of Kontakt, so it doesn't matter which library you use. So, generally, every product that can send Midi data, you can send it out of Kontakt.

then if you want to record the midi from Kontakt, you should open new MIDI channel and set input of this channel from Kontakt

option in Kontakt