Silverlight custom control ToolTip not showing up each time -
In Silverlight application, I have a custom control with many custom properties to define your properties as dependency properties In the category of custom control announcement, I am showing tooltips:
public override zero OnApplyTemplate () {base.OnApplyTemplate (); Border bordercntr = base.GetTemplateChild ("PART_SBorder") as the boundary; Bordercntr.MouseEnter + = New MouseEventHandler (bordercntr_MouseEnter); Bordercntr.MouseLeave + = New MouseEventHandler (bordercntr_MouseLeave); } Private Zero limitcntr_MouseEnter (Object Sender, MouseEventArgs e) {string _sno = this.SomeProperty.ToString (); ToolTipService.SetToolTip (this, "some text" + _sno); Visualstatizer Gostostat (This, "hovers", false); }
The problem is that tooltip does not pop up mouse poinces for a custom control for the first time, but after reloading the page only after the second time, Happens: For the first time when I hover over any control, nothing is visible and the second time the tooltip is again fashioned (not always in a steady manner, I mean every time that the mouse is trapped 100%).
What can prevent the tooltip from appearing in a steady manner, when every time a mouse is grounded on the control and after reloading the page it may appear from the very first time of rotation? Tooltip in setter> ToolTip Code> ToolTipService , behave like a normal tooltip and will only appear when mouse is on control. SomeProperty
MouseEnter
and mouse move
events should not be necessary to handle everyone.
Comments
Post a Comment