Professional UI Solutions
Site Map   /  Register


Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Elegant Ribbon Tech Support » error on pressing any key while ScreenTips is displayed Collapse All
Subject Author Date
Victor Derevyanko Nov 21, 2008 - 12:09 AM

If i set screentip.Text for any control on the ribbon, and move mouse point to this control, the screentip is displayed. Now, if I press any key during displaing screentip (f.e. Esc, space or ’0’) i receive a message box with error:

An unhandled exception of type ’System.ObjectDisposedException’ occurred in System.Windows.Forms.dll

Additional information: Cannot access a disposed object.

I have reproduced this error on the very simple application - with only one form with ribbon and single button on it. This application works with this error on two my computers. But it works without any problems on the computer of my coleague and on the virtual machine. So I am not sure that it’s 100% reproducable.

My system configuration:
VS2005, Net 2.0
Elegant Ribbon 3.1 + fix (see topic "Default theme + license")
Windows XP sp 2 eng

The stack trace for the error is:

    System.Windows.Forms.dll!System.Windows.Forms.Control.CreateHandle() + 0x20d bytes    
    System.Windows.Forms.dll!System.Windows.Forms.Form.CreateHandle() + 0xb8 bytes    
    System.Windows.Forms.dll!System.Windows.Forms.Control.Handle.get() + 0x5d bytes    
    Elegant.Ui.Common.dll!Elegant.Ui.PopupImplementationForm.PassKeyboardToControl() + 0x13 bytes    
    Elegant.Ui.Common.dll!Elegant.Ui.PopupImplementationForm.OnInputSpyKeyDown(Elegant.Ui.InputSpyKeyEventArgs e = {KeyData = Space}) + 0xe5 bytes    
    Elegant.Ui.Common.dll!Elegant.Ui.InputSpy.KeyboardHookProc(int nCode = 0, System.IntPtr wParam = 32, System.IntPtr lParam) + 0xfb bytes    
    [Native to Managed Transition]    
    [Managed to Native Transition]    
    System.Windows.Forms.dll!System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(int dwComponentID, int reason = -1, int pvLoopData = 0) + 0x273 bytes    
    System.Windows.Forms.dll!System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(int reason = -1, System.Windows.Forms.ApplicationContext context = {System.Windows.Forms.ApplicationContext}) + 0x17d bytes    
    System.Windows.Forms.dll!System.Windows.Forms.Application.ThreadContext.RunMessageLoop(int reason, System.Windows.Forms.ApplicationContext context) + 0x53 bytes    
    System.Windows.Forms.dll!System.Windows.Forms.Application.Run(System.Windows.Forms.Form mainForm) + 0x2e bytes    
>    WindowsApplication1.exe!WindowsApplication1.Program.Main() Line 16 + 0x1a bytes    C#

Have you any ideas what can be a reason of such error?
Thanks in advance,
Regards, V.D

Technical Support Nov 24, 2008 - 3:21 AM

It looks like the bug is already fixed so the fix will be available in the next release.The reason for the exception throwing is that the Control.Handle property is used after the control is actually disposed. This results in an attempt to create a window handle which is not allowed by that moment. Thank you!

Victor Derevyanko Dec 10, 2008 - 7:56 AM

Can you tell me approx date of the new release of Elegant Ribbon? We are going to release our application at the end of this year, but this bug is rather serious to simply ignore it. Of course, I can switch off all screentips, but may be it’s not necessary?
Thanks in advance,
Regards, V.D

Technical Support Dec 11, 2008 - 10:12 AM

Least of all we would like to let you down. So what do you think if we provide you with an updated 3.1 that features some bug fixes including that you are talking about?

Victor Derevyanko Dec 11, 2008 - 6:41 PM

Thanks, it would be excelent.
Will you send it to me by email?