How to get Tooltip text from Infragistic Chart

Technology specific object identification, supported applications, web technologies, and 3rd party controls.
thangavel
Posts: 50
Joined: Tue Jun 09, 2009 6:48 am
Contact:

How to get Tooltip text from Infragistic Chart

Post by thangavel » Thu Aug 13, 2009 3:00 pm

Hi,

I have one web application, which contains infragistics charts and standard SilverLight controls (SilverLight 3.0). I need to get Tooltip text from that Chart/ Silverlight controls.

Please help me on this.
Regards,
Thangavel.S

User avatar
Support Team
Site Admin
Site Admin
Posts: 11710
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: How to get Tooltip text from Infragistic Chart

Post by Support Team » Thu Aug 13, 2009 5:08 pm

Please, try to use the ToolTip adapter you get by calling Ranorex.ToolTip.Current. The corresponding RxPath is "/tooltip".

Regards,
Alex
Ranorex Support Team
.
Image

thangavel
Posts: 50
Joined: Tue Jun 09, 2009 6:48 am
Contact:

Re: How to get Tooltip text from Infragistic Chart

Post by thangavel » Fri Aug 14, 2009 11:16 am

Hi

Code: Select all

//C# code
string s = Ranorex.ToolTip.Current.Text;
The above code is fetching normal window tooltips but not SilverLight Tooltips.
The Following code is to get the text from the PlotArea, move the cursor to the text then wait 2 seconds for the tool tip displayed. then tried to get all the Tooltip descendants. But it returns empty.

Code: Select all

//C# code
Ranorex.Text polymer = SLForm.FindSingle("./container[@automationid='scrollContent']/text[@name='Polymer']");
webDocument.Browser.Activate();
Ranorex.Mouse.MoveTo(polymer.Element.ScreenLocation.X, (polymer.Element.ScreenLocation.Y - 200));
System.Threading.Thread.Sleep(2000);
IList<Ranorex.ToolTip> tt = SLForm.FindDescendants<Ranorex.ToolTip>();
When I mouse over to the chart, some tooltip will be displayed. I need to capture that. Refer the screenshot.
ToolTip_Chart_Infragistics.JPG
VISIFIRE CHARTS
ToolTip_Chart_Infragistics.JPG (21.11 KiB) Viewed 4977 times
Regards,
Thangavel.S

User avatar
Support Team
Site Admin
Site Admin
Posts: 11710
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: How to get Tooltip text from Infragistic Chart

Post by Support Team » Fri Aug 14, 2009 12:16 pm

I just tried to reproduce that issue with the Infragistic Silverlight samples on their homepage. In the samples that have a tooltip, the ToolTip element is always a descendant of the "SilverLight Control" element, i.e. a search using FindDescendants<Ranorex.ToolTip>() on that element should give you the tooltip element. I can't guarantee that your Silverlight control behaves the same way, though.

The easiest way to check whether your Silverlight control provides a tooltip element is to take a snapshot of the control while a tooltip is visible and then inspect that snapshot. To do that track the Silverlight control using the "Track" button or "Instant Tracking" in Ranorex Spy, move over the control to make the tooltip appear, and when the tooltip appears press the "Scroll Lock" key on your keyboard to make a snapshot of the Silverlight element you tracked before (see topic "Snap shots from popup windows, dropdown combo boxes or dropdown menus" in the Ranorex User Guide http://www.ranorex.com/support/user-gui ... html#c2072).
Once you have the snapshot, watch for a "Popup" element that is a direct child of the "Silverlight Control" element. With my Infragistics samples there was always a tooltip element inside that "Popup" element.

Regards,
Alex
Ranorex Support Team
.
Image

thangavel
Posts: 50
Joined: Tue Jun 09, 2009 6:48 am
Contact:

Re: How to get Tooltip text from Infragistic Chart

Post by thangavel » Fri Aug 14, 2009 12:41 pm

Hi,

Thanks for your clarifiaction.
I tried this approach also - FindDescendants<Ranorex.ToolTip>()
But it returns null.

I have communicated the development team to investigate about the Chart.
That chart is developed using VISIFIRE charts (Open Source Silverlight & WPF Chart Controls. With Visifire you can create and embed animated charts in minutes). Is there any support for visifire charts?
Regards,
Thangavel.S

User avatar
Support Team
Site Admin
Site Admin
Posts: 11710
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: How to get Tooltip text from Infragistic Chart

Post by Support Team » Fri Aug 14, 2009 12:54 pm

I just checked with the Visifire SL samples ("DateTimeAxis.htm"), actually they provide quite good automation support. There is a text element ("text[@automationid='ToolTipTextBlock']") that corresponds perfectly to the tooltip. Just get that element and check out its the Visible and Text properties.

Regards,
Alex
Ranorex Support Team
.
Image

thangavel
Posts: 50
Joined: Tue Jun 09, 2009 6:48 am
Contact:

Re: How to get Tooltip text from Infragistic Chart

Post by thangavel » Fri Aug 14, 2009 2:33 pm

Hi Alex,

Thanks a lot for your support. I just tried to get all visible TEXT descendants within the form. It is working perfectly. :D
Regards,
Thangavel.S