cancel
Showing results for 
Search instead for 
Did you mean: 

aqObject.CheckProperty to verify the item selected in the dropdown

SOLVED
Occasional Contributor

aqObject.CheckProperty to verify the item selected in the dropdown

Hi 

I am new to test complete scripting.

I am using chrome . Need to verify the default value selected in the dropdown.

 

the below code is used

titleCombo = p.NativeWebObject.Find("id","TitleId","SELECT");
Log.Message(titleCombo.wSelectedItem);  // returning 0
aqObject.CheckProperty(titleCombo,"titleCombo.wSelectedItem",cmpEqual,"0");

 

It is throwing error saying invalid property name. Pls help

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Hero

Re: aqObject.CheckProperty to verify the item selected in the dropdown

Hi,

 

The name of the property is wSelectedItem but not the titleCombo.wSelectedItem.

Thus, I think that the last line should be like this:

aqObject.CheckProperty(titleCombo,"wSelectedItem",cmpEqual,"0");

 

Regards,
Alex
[Community Expert Group]
____
[Community Expert Group] members are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Postings made by [Community Expert Group] members
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
[Community Expert Group] signature is used with permission by SmartBear Software.
http://smartbear.com/forums/f83/t86934/community-experts/
================================
2 REPLIES 2
Highlighted
Community Hero

Re: aqObject.CheckProperty to verify the item selected in the dropdown

Hi,

 

The name of the property is wSelectedItem but not the titleCombo.wSelectedItem.

Thus, I think that the last line should be like this:

aqObject.CheckProperty(titleCombo,"wSelectedItem",cmpEqual,"0");

 

Regards,
Alex
[Community Expert Group]
____
[Community Expert Group] members are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Postings made by [Community Expert Group] members
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
[Community Expert Group] signature is used with permission by SmartBear Software.
http://smartbear.com/forums/f83/t86934/community-experts/
================================
Occasional Contributor

Re: aqObject.CheckProperty to verify the item selected in the dropdown

Thanks it is working.

New Here?
Join us and watch the welcome video:
Top Kudoed Authors