This is a migrated thread and some comments may be shown as answers.

Need a quicktask for the RadButton

3 Answers 63 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
sitefinitysteve
Top achievements
Rank 2
Iron
Veteran
sitefinitysteve asked on 04 Apr 2011, 03:26 PM
I need a quicktask to get me the Text value of the button, AND the current PrimaryIconCss (or SecondaryIconCss) values...

It lets me do such great clientside stuff, I need to validate it's text and css state...

3 Answers, 1 is accepted

Sort by
0
Stoich
Telerik team
answered on 07 Apr 2011, 05:31 PM
Hello Steve,
    I create an html page that consists of a single element:
<INPUT type="image" src="/b.PNG" value="myvalue">
b.PNG is a PNG image located in the same folder as that the html page is located in. Now we want to get the value and the src attributes. Here's a very generic piece of code that will get the job done:
Element b = Find.ByExpression("id=myButton");
   
       foreach (iAttribute i in b.Attributes) {
 
           if (i.Name.Equals("value"))
           {
               Log.WriteLine("Value-->" + i.Value);
           }
 
           if (i.Name.Equals("src")) {
           Log.WriteLine("Image src-->"+i.Value);
           }
       }
That will write the image src and the value to the log. I think you probably needed something more complex.
In that case please go ahead and give a bit more detail on your automation task and what you need in order to make it work.

Hope to hear from you soon!

Best wishes,
Stoich
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
sitefinitysteve
Top achievements
Rank 2
Iron
Veteran
answered on 07 Apr 2011, 05:35 PM
No, not sure it's a complex request :) ...at least on my end

I just would like the RadButton Webaii Translator to allow verification of the Text value in the button and\or the assigned icon CSS :)  Not A button, the RAD button (if that makes sense?)

http://demos.telerik.com/aspnet-ajax/button/examples/buttonheight65pixels/defaultcs.aspx

I don't want to generate code to keep checking, I just want the little hover-over quick tasks to let me validate the RadButton text.  Like right now I can really only get basic stuff like "Enabled"...
0
Stoich
Telerik team
answered on 13 Apr 2011, 09:25 AM
Hello Steve,
    you can verify a RadButton's text now. Highlight the button and bring up the popup menu.
From the popup menu click on "Build Verification" (see screenshot 1). From here you'll be able to add a text value Verification (screenshot 2). With the Verification Builder you can build create a multitude of different Verifications related to style, font, color, content etc.

 You can bring up the Verification Builder on the root element (screenshot 3) for additional verifications. For instance you can build css-related verification only on the root element.

I hope this helps, let me know if you have any other questions!

Regards,
Stoich
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
General Discussions
Asked by
sitefinitysteve
Top achievements
Rank 2
Iron
Veteran
Answers by
Stoich
Telerik team
sitefinitysteve
Top achievements
Rank 2
Iron
Veteran
Share this question
or