We are developing a mixed c++ application were we host a usercontrol within an MFC CWinFormsView. This control contains UltraToolbars with PopupMenuTool dropdown menus.
We are experiencing problems with the dropdown menus remaining sticky on the screen when the mouse clicks outside the menu or the form is moved or closed. Furthermore, the Escape doesn't work for closing the menus or any other shortcut key assigned to a menu entry. We also have a WinNavigationBar that has the same problems when a dropdown for a location is opened.
Could you please advise?
Carlo
Its funny, I haven't seen anyone have this issue before, and now it has happened twice in the past 10 days (here is the other post: http://forums.infragistics.com/forums/p/2827/17955.aspx). It appears your are having the same problem. Here is the solution that worked before:
Add a call to Infragistics.Win.Utilities.ForceNativeMessageFilter() to the constructor of the UserControl. I say to add this call to the constructor and not to the start of the application because it doesn't hurt to call this method multiple times and calling it only applies to the thread it was called on. In a multi-threaded application, you would want to make sure the the fix is applied to user controls instantiated on all threads.
Thanks Mike, that worked great for the menus sticking on the screen. However the shortcut keys or the escape key for closing the menu still don't work. Do you have any suggestions for that?
The sticky popup menu and shortcut keys problems happen about 90% of the time in our environment (winform, debug or release build, single and dual core machines, XP, VS2005, .NET 2.0, community of 50+ developers and QA, hundreds of users). We are going to roll out our software very soon to many thousands of users. This is a very serious usability issue and I urge Infragistics to look into the problems and provide a solution soon. (and when I contact your support, they just replied back with a very, very simple program citing "cannot reproduce").
I have also tried taking out our application specific code, even putting return statements at the beginning of the main form's constructor and load event without any success.
ps. Again, we believe this is a problem with UltraToolbarsManager. We are using the Ribbon control.
Regards,
Roger
Are you guys having problems with alt key navigation? I CAN assign a shortcut key combination to a tool and it WILL work. However, in my app, I do NOT get the correct behavior when clicking Alt and using menu mnemonics.
The form that I am using has an UltraToolbarsManager control along with some other controls. Specficially, the form is being launched within a command in ESRI's ArcMap application. I created a sample command with a simple form with an UltraToolbarsManager and can get the navigation to work. However, in my more complicated form, the navigation won't work. Clicking Alt doesn't even activate the menu bar.
Are others seeing this same problem?
It sounds like another control on your form is processing the Alt key before it can get to the toolbars manager. Try making a copy of the more complicated form and removing controls from the main form one by one to see which control is causing the issue.
Mike, thanks for your reply.
I have already tried that. I removed all of the other controls on the form and removed all of the code that was catching and forwarding the KeyDown, Up, and Press events. That is why I was wondering if this was a bug as described by earlier posts.
As I mentioned before in my previous posts, the sticky popup menu and shortcut keys (alt key) problems are believed to be related - if anyone of these two happen, the other problem also surfaces. I have contact Infragistics support several times and they said they could not reproduce the problems (of course, they use very, very small programs and it is impractical to send them our app). I also sent them screen shot to proof that there is such a problem without any resolution.
You may be correct when you say that the sticky popup menu and alt key problems are related. I, too, was having the sticky popup menu problem and added the Infragistics.Win.Utilities.ForceNativeMessageFilter() line of code. This fixed the sticky menu problem. However, I cannot determine anything in my code that would be causing the alt key functionality to not work. As I have said in a previous post, the design-time assigned shortcut keys work, but the mnemonic-driven menus will not work.
I have removed all other controls from my form, thus removing the possibility that another control might be stealing focus and absorbing my alt key message.