Hi - sorry it took so long to get back to you.
I have done some digging into this issue.
This issue appears to be an issue within GR5, and NOT caused by Sonar. I base this on testing out the midi learn function of GR 5 in 2 separate host products - Sonar and another VST host called Forte.
In BOTH host products, GR 5 fails to properly process the learn function.
I did get some additional info when trying to get it to work in the Forte program. (In Sonar, after right-clicking in GR 5 on a control knob it just sits there instead of telling me about the learn event. In Forte, it also just sits there UNTIL immediately after I go back and insert a synth in Forte. As soon as I add a soft-synth into Forte, all of a sudden a message box pops up that is coming not from the newly-inserted synth, but from GR 5 - talling me that the CC # for the knob I was trying to train was already set to something else.
In other words, GR 5 has an internal process flow of what itis supposed to do when amidi learn event is being handled, and in stand alone mode it processes correctly. But when running as an inserted effect - which is what GR 5 does these days, that process flow seems to fall apart - like it gets stuck. It then wakes up and smells the roses only when some other event occurs and THEN posts messages like it should have done in the first place.
Based on the fact that it is not just Sonar,but also Forte that GR 5 is having trouble with, I believe this to be a Native Instruments bug in GR 5.
This was further confirmed by a phone call I made this morning to Germany - to speak with the Native Instruments technical support folks about the apparent problem.
They at first were suggesting that there was some configuration thing that needed to take place in Sonar to be able to do the learn, but they themselves hooked up a midi controller to Sonar and were able to duplicate the problem.
This got them to head scratching, and they are going to look into this further at their end and will follow up with me via email someday in the future.
In the meantime, I believe you are out of luck getting this to work within Sonar.
I will post back as soon as I hear back from NI, and will follow up with them in a couple of weeks if I don't get any emails from them before then.
Bob Bone