It was possible to map current value to "friendlyname" and so to MIDI, as i have described before (and you has confirmed it works).
The "barrier" to do reversed operation was the luck of such function.
Well, check current test version. There must be "Set IO from Text" Function. It does that. So, you need set current text to the name (with Text Action) and select input/output (as on your screenshot), then call this function. If the input with such name is found, that input is selected.
The problem... that part of Cakewalk is historically buggy... And I had too much frustration dealing with that bugs before. But for hardware inputs it should work.
With "software synth" input there are already some glitches, in my tests "mono" inputs for some reason are reported as "stereo", even on mono tracks.
Once you insert plug-ins with side chains, "Send output" goes crazy. And so on. That is why I have recommended to use some unrelated parameters to control IO on your device.
Please don't say I have not warned you (now twice) in case you observe some strange effects with IO parameters.