I'm using ultrawintoolbars 5.3 in a project (VS.net C# windows app) on terminal server. Randomly I get the error "the object is currently in use elsewhere." I've searched your forums and found a discussion about this that ended without a stated resolution in the thread. The Infragistics employee that answered was Andrew Smith. He though there was a hotfix for this somewhere. This thread happened Oct 12,2006. Here is the link to the thread:
http://news.archive.infragistics.com/readmessage?id=%3C7e787976$4227cd95$50f3b@news.infragistics.com%3E&group=infragistics.products.netadvantage.windowsforms.wintoolbars
I'm getting the same exact JIT details as in the thread.
Here is the JIT details:
> ************** Exception Text **************> System.InvalidOperationException: The object is currently in use > elsewhere.> at System.Drawing.Image.get_Height()> at System.Drawing.Image.get_Size()> at> Infragistics.Win.UltraWinToolbars.PopupToolBase.CalculateLogicalSizeOfToolInstance()> at Infragistics.Win.UltraWinToolbars.ToolBase.get_WidthResolved()> at > Infragistics.Win.UltraWinToolbars.ToolbarUIElement.PositionChildElements()> at Infragistics.Win.UIElement.VerifyChildElements(ControlUIElementBase> controlElement, Boolean recursive)> at Infragistics.Win.UIElement.VerifyChildElements(ControlUIElementBase> controlElement, Boolean recursive)> at Infragistics.Win.UIElement.DrawElement(UIElementDrawParams&> defaultDrawParams)> at Infragistics.Win.UIElement.DrawHelper(Graphics graphics, Rectangle> invalidRectangle, Boolean doubleBuffer, AlphaBlendMode alphaBlendMode, > Boolean> clipText, Boolean forceDrawAsFocused)> at Infragistics.Win.UIElement.Draw(Graphics graphics, Rectangle> invalidRectangle, Boolean doubleBuffer, AlphaBlendMode alphaBlendMode)> at Infragistics.Win.ControlUIElementBase.Draw(Graphics graphics, > Rectangle> invalidRectangle, Boolean doubleBuffer, AlphaBlendMode alphaBlendMode, > Size> elementSize)> at Infragistics.Win.ControlUIElementBase.Draw(Graphics graphics, > Rectangle> invalidRectangle, Boolean doubleBuffer, AlphaBlendMode alphaBlendMode)> at Infragistics.Win.UltraControlBase.OnPaint(PaintEventArgs pe)> at> Infragistics.Win.UltraWinToolbars.UltraToolbarsDockArea.OnPaint(PaintEventArgs > pe)> at System.Windows.Forms.Control.PaintWithErrorHandling(PaintEventArgs e,> Int16 layer, Boolean disposeEventArgs)> at System.Windows.Forms.Control.WmPaint(Message& m)> at System.Windows.Forms.Control.WndProc(Message& m)> at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)> at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)> at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg,> IntPtr wparam, IntPtr lparam)
Phruby, did you try a hotfix, and did it work around the problem? I'm also seeing it in my use of the toolbars. I should add I'm using v 7.3.
Also, to Infragistics support, it doesn't compute that an old hotfix is mentioned here and in the other thread, but we're on 7.3. Have there been no more recent examples of this still occurring? Can you tell me more about how I can work around this in my own code? What I think is happening is that I'm using the same image resource from more than one tool, and some kind of race condition is occuring on accessing the image resource. Can you confirm, or suggest anything else that might be a problem?
tamalerishi,
tamalerishi said:Have there been no more recent examples of this still occurring? Can you tell me more about how I can work around this in my own code?
My best suggestion to get this issue resolved is to get to us a sample we can use to reproduce the behavior. With such a sample that we can run and debug, we can investigate in-depth to determine a cause. This may or may not point out a bug we need to fix in our toolset, or one that we may have already fixed in later hot fixes and/or volume releases. Also, this may or may not provide us with enough information to suggest a workaround.
Hi,
the error occurs suddenl;y to me too. I am using NetAdvantage 2008.3 on Vista business 64. Everything worked sweet as until this morning. Now I get this exception even in the designer.
Here the stacktrace I get when I start my application (the ribbon is a big red cross):
After a "Clean solution", PC reboot and "Rebuild solution" it worked again.
I assume it happened, when I left the office, but the application was still running in debug mode for about 18 hours