bitman
In a nutshell, I don't think Cakewalk can control this or they would have. AFAIK, Windows is rearranging things.
Someone will come along and tell me I'm wrong if I am.
Sorry, but you are a kind of wrong

The only case when a program can loose the track of USB devices is where there are 2 or more exactly equivalent devices which are re-connected to different USB ports. Logically, nothing can detect which device is moved where since they usually do not have unique (per exemplar) ID.
Unfortunately, Sonar is not the best MIDI devices detection software.
The only set of options a user has is to use Windows Device Manager, enable "show hidden" and clean up all old MIDI ports (every time USB is connected to different port, "new" device is created). And remove "TTSSEQ.INI" in %APPDATA%\Cakewalk\<version>.
There was a claim one of recent BandLab updates was supposed to fix some floating bug.