EDN Admin
Well-known member
Hi,<br/>
<br/>
i am facing a problem i simply dont understand: When i set the RichTextBox.WordWrap to "true", the RichTextBox "Visible" property is set to "false" and when i set the WordWrap to "false" the "Visible" property is "true" again. Either this is a bug in the control
or something i miss. Here is a full CallStack from the failing procedure:<br/>
<br/>
<pre>MediVan.Classes.mvRichTextBoxExClass.OnVisibleChanged(EventArgs e)
System.Windows.Forms.Control.SetVisibleCore(Boolean value)
System.Windows.Forms.Control.set_Visible(Boolean value)
MediVan.mvMainForm.mvToolStripMenuItemClassWordWrap_Click(Object sender, EventArgs e)
System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
System.Windows.Forms.Control.WndProc(Message& m)
System.Windows.Forms.ScrollableControl.WndProc(Message& m)
System.Windows.Forms.ToolStrip.WndProc(Message& m)
System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(Int32 dwComponentID, Int32 reason, Int32 pvLoopData)
System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
System.Windows.Forms.Application.Run(Form mainForm)
MediVan.mvMainProgram.Main(String[] args)[/code]
<br/>
This is what is inside the "MediVan.mvMainForm.mvToolStripMenuItemClassWordWrap_Click(Object sender, EventArgs e)"<br/>
<br/>
<pre>this.mvToolStripMenuItemClassWordWrap.Checked = !this.mvToolStripMenuItemClassWordWrap.Checked;
this.mvRichTextBoxExmvMessages.WordWrap = this.mvToolStripMenuItemClassWordWrap.Checked;[/code]
This is absolutely weird, since the RichTextBox (it is extended by some "static" propertys, no hooking, no subclassing) has absolutely no "this.Visible" reference inside the class or anything that changes the visible state. How can this be??? Any ideas???<br/>
<br/>
regards<br/>
<br/>
Kerem<br/><hr class="sig ------------------------- Beste Grüsse / Best regards / Votre bien devoue Kerem Gümrükcü http://entwicklung.junetz.de ------------------------- "This reply is provided as is, without warranty express or implied."
View the full article
<br/>
i am facing a problem i simply dont understand: When i set the RichTextBox.WordWrap to "true", the RichTextBox "Visible" property is set to "false" and when i set the WordWrap to "false" the "Visible" property is "true" again. Either this is a bug in the control
or something i miss. Here is a full CallStack from the failing procedure:<br/>
<br/>
<pre>MediVan.Classes.mvRichTextBoxExClass.OnVisibleChanged(EventArgs e)
System.Windows.Forms.Control.SetVisibleCore(Boolean value)
System.Windows.Forms.Control.set_Visible(Boolean value)
MediVan.mvMainForm.mvToolStripMenuItemClassWordWrap_Click(Object sender, EventArgs e)
System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
System.Windows.Forms.Control.WndProc(Message& m)
System.Windows.Forms.ScrollableControl.WndProc(Message& m)
System.Windows.Forms.ToolStrip.WndProc(Message& m)
System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(Int32 dwComponentID, Int32 reason, Int32 pvLoopData)
System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
System.Windows.Forms.Application.Run(Form mainForm)
MediVan.mvMainProgram.Main(String[] args)[/code]
<br/>
This is what is inside the "MediVan.mvMainForm.mvToolStripMenuItemClassWordWrap_Click(Object sender, EventArgs e)"<br/>
<br/>
<pre>this.mvToolStripMenuItemClassWordWrap.Checked = !this.mvToolStripMenuItemClassWordWrap.Checked;
this.mvRichTextBoxExmvMessages.WordWrap = this.mvToolStripMenuItemClassWordWrap.Checked;[/code]
This is absolutely weird, since the RichTextBox (it is extended by some "static" propertys, no hooking, no subclassing) has absolutely no "this.Visible" reference inside the class or anything that changes the visible state. How can this be??? Any ideas???<br/>
<br/>
regards<br/>
<br/>
Kerem<br/><hr class="sig ------------------------- Beste Grüsse / Best regards / Votre bien devoue Kerem Gümrükcü http://entwicklung.junetz.de ------------------------- "This reply is provided as is, without warranty express or implied."
View the full article