If a usercontrol which contains ultratoolbarsmanager is hosted inside WPF WindowsFormsHost, shortcut keys on ultratoolbar tools are not working. Is this a known issue and is there any workaround?
Any help would be appriciated,
thanks,
Jurica
The sample I refer to above is the one that is on the other thread.
I'll try your most recent sample in the morning too.
Looks like the implementation of IsControlOnActiveForm in your example walks up the window heirarchy until it reaches the first child of the active form, but then the call to NativeWindowMethods.GetParent returns IntPtr.Zero for that form, rather than the hwnd of the parent Window.
In this case, the parent window is the WPF window (though I believe there is more in that hwnd heirarchy that is WPF which is being walked correctly.
Spy++ does correctly show the parent window for the, so not sure why that final GetParent() call is not working from c#.
I gotta head off, but i'll keep going with this tomorrow and let you know if I figure out whats going on.
I've attached a sample which uses the derived UTM I posted in that thread. Ctrl+S is the shortcut assigned to the button.
I just went and tried a derived implementation like you suggest in that other thread but this doesn't seem to solve the problem.
Could this be because I've simply used your default implementation of FormWindowState?
To be honest, I'm not sure what I would have to implement here.
I used this in conjunction with the call to Infragistics.Win.Utilities.ForceNativeMessageFilter();
I just tried this and you are correct. It looks like my answer was not complete. You need to force the native message filter, but you also need to create a derived UltraToolbarsManager. There is a thread where this was discussed and I posted a starting point for the derived manager which should help you. Here is the post where I provide the derived manager: http://community.infragistics.com/forums/p/3349/25277.aspx#25277