Hello
I am trying to check the color property of a FlexElement and I am not sure how to do this. Is there a way to get the color property of an element. I have also tried to use Ranorex Spy to see if there is an explicit property (of the Element I am trying to work with) which deals with the color, but no help. Any ideas?
Thanks for the help
Way to get the color property of Flex Element
-
- Posts: 3
- Joined: Mon Dec 06, 2010 4:22 pm
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Way to get the color property of Flex Element
Hi,
Please take a look to following post. Maybe the code sample in it solves your problem to get the color of your element. http://www.ranorex.com/forum/flexelemen ... t1734.html
Another solution would be to write the color to an property which is visible for Ranorex out of the box, for example description. Then you can use the RxPath to get the color of your element.
Regards,
Peter
Ranorex Team
Please take a look to following post. Maybe the code sample in it solves your problem to get the color of your element. http://www.ranorex.com/forum/flexelemen ... t1734.html
Another solution would be to write the color to an property which is visible for Ranorex out of the box, for example description. Then you can use the RxPath to get the color of your element.
Regards,
Peter
Ranorex Team
-
- Posts: 3
- Joined: Mon Dec 06, 2010 4:22 pm
Re: Way to get the color property of Flex Element
Thanks for the reply Peter, the post was helpful. I had another question about the color property which I wasn't able to get an answer for from the previous post.
In my application, I have a LinkButton which I am converting into a FlexElement using the repository path. What I would like to do is get the color of the font and check this value against my desired value. When I do GetStyle("color") on this button, I do not get the right color value. I have tried doing GetStyle("font-color")/ GetStyle("fontcolor") but no help. Could you tell me if there is a way to get the proper font color of a FlexElement? Does GetStyle("color") work differently on LinkButton Flex Elements?
Thanks
In my application, I have a LinkButton which I am converting into a FlexElement using the repository path. What I would like to do is get the color of the font and check this value against my desired value. When I do GetStyle("color") on this button, I do not get the right color value. I have tried doing GetStyle("font-color")/ GetStyle("fontcolor") but no help. Could you tell me if there is a way to get the proper font color of a FlexElement? Does GetStyle("color") work differently on LinkButton Flex Elements?
Thanks
- Support Team
- Site Admin
- Posts: 12145
- Joined: Fri Jul 07, 2006 4:30 pm
- Location: Houston, Texas, USA
- Contact:
Re: Way to get the color property of Flex Element
Hi,
the GetStyle method provided by Ranorex directly accesses the Flex object. So it should be possible to get all style elements provided by the Flex element thru this method.
So please find out how exactly the property you want to get can be accessed.
Kind regards,
Tobias
Support Team
the GetStyle method provided by Ranorex directly accesses the Flex object. So it should be possible to get all style elements provided by the Flex element thru this method.
So please find out how exactly the property you want to get can be accessed.
Kind regards,
Tobias
Support Team