|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
problem with tooltip on 2.0 frameworkI am experiencing a strange problem for the call setToolTip while running my application on frmaework 2.0. I have found 2 messages on google discussing the same issue but there are no replys It dumps saying something like System.InvalidOperationException: Adding the tip to the native ToolTip control did not succeed. at System.Windows.Forms.ToolTip.SetToolInfo(Control ctl, String caption) at System.Windows.Forms.ToolTip.CreateRegion(Control ctl) at System.Windows.Forms.ToolTip.CreateAllRegions() at System.Windows.Forms.ToolTip.get_TopLevelControl() at System.Windows.Forms.ToolTip.CreateRegion(Control ctl) at System.Windows.Forms.ToolTip.HandleCreated(Object sender, EventArgs eventargs) at System.Windows.Forms.Control.OnHandleCreated(EventArgs e) at System.Windows.Forms.Control.WmCreate(Message& m) at System.Windows.Forms.Control.WndProc(Message& m) at System.Windows.Forms.Label.WndProc(Message& m) at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m) at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m) at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam) The strange thing about this that it cannot be caught in the try catch blocks. Actually I have set the tooltip to most of the controls in my application. It sets and displays it properly but somewhere in the middle it dumps. The trace I am getting won't tell me exactly to which tooltip it dumps so I am not able to figure out exactly. Does anybody has found any solution for such problem Thanks in advance <sonali_reddy***@yahoo.com> wrote in message
Show quote news:1161325619.659002.23950@h48g2000cwc.googlegroups.com... I think a try-catch in your main method around Application.Run will > Hi all, > > I am experiencing a strange problem for the call setToolTip while > running my application on frmaework 2.0. I have found 2 messages on > google discussing the same issue but there are > no replys > > It dumps saying something like > System.InvalidOperationException: Adding the tip to the native ToolTip > control did not succeed. > at System.Windows.Forms.ToolTip.SetToolInfo(Control ctl, String > caption) > at System.Windows.Forms.ToolTip.CreateRegion(Control ctl) > at System.Windows.Forms.ToolTip.CreateAllRegions() > at System.Windows.Forms.ToolTip.get_TopLevelControl() > at System.Windows.Forms.ToolTip.CreateRegion(Control ctl) > at System.Windows.Forms.ToolTip.HandleCreated(Object sender, > EventArgs eventargs) > at System.Windows.Forms.Control.OnHandleCreated(EventArgs e) > at System.Windows.Forms.Control.WmCreate(Message& m) > at System.Windows.Forms.Control.WndProc(Message& m) > at System.Windows.Forms.Label.WndProc(Message& m) > at > System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m) > at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& > m) > at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 > msg, IntPtr wparam, IntPtr lparam) > > The strange thing about this that it cannot be caught in the try catch > blocks. intercept it. > Actually I have set the tooltip to most of the controls in my If you open the stack frame for > application. It sets and displays it properly but somewhere in the > middle it dumps. The trace I am getting won't tell me exactly to which > tooltip it dumps so I am not able to figure out exactly. System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam) and look at hWnd, then open Spy++, you can find out what the HWND corresponds to. Likely it will be the tooltip control itself, so find out what message (starting with TTM_) msg is. Look that up on MSDN, and it will explain what wparam and lparam mean. Show quote > > Does anybody has found any solution for such problem > > Thanks in advance > |
|||||||||||||||||||||||