Hi all,
I am trying to capture Role and name proeprty for toolstrip items but I could not . Is there any specific win32APIs for capturing these proerties?
Please clarify me.
Thanks,
Mohan
Capturing Role and Name property
-
- Posts: 2
- Joined: Wed Aug 01, 2007 6:59 am
- Location: Bangalore
- Contact:
The following sample code works with the VS2005Application.exe (Ranorex\Bin\Net2.0 directory).
It searches the toolstrip of the application, finds the toolstrip item with the Role=PushButton and Name="Test Progressbar" and clicks the button.
Jenö
Ranorex Team
It searches the toolstrip of the application, finds the toolstrip item with the Role=PushButton and Name="Test Progressbar" and clicks the button.
Code: Select all
ToolStrip toolStrip = form.FindToolStrip("toolStrip1");
if (toolStrip != null)
{
// Find the pushbutton of the toolstrip by Role=PushButton and Name="Test Progressbar"
Element progressBarButton = toolStrip.Element.FindChild(Role.PushButton, "Test Progressbar");
if (progressBarButton != null)
Mouse.ClickElement(progressBarButton);
}
Ranorex Team
-
- Posts: 2
- Joined: Wed Aug 01, 2007 6:59 am
- Location: Bangalore
- Contact: