I am using QTP 9.1 to automate test cases.The application has an UltraWinGrid and am trying to find a row using a search strig.I want to find the rowcount to loop through the rows to find out my search string.When I used rowcount property,I got a message saying this property is not supported.
Please let me know how do I go about that.
Thanks,
RamPriya
Hello Neeta,
If you still have any concerns or questions I will be glad to help. If you need any additional assistance don’t hesitate to ask.
Regards
Neeta,
I believe the approach that I posted here will work for you.
Let me know if you have any questions.
Hi Georgi,
Thanks for your post. I have 1 more issue regarding the same. In non filtered grid, we have some 5000+ rows as of now. After filter, there is only 1 row. I have to fetch the values of few columns of this particular row. This particular valued row may appear at any row between this row count. So, I cant iterate every row to get its value. Is there any method through which I can retrieve filtered row values without iterating 5000 rows?
Have you been able to resolve your issue ? If you still have any concerns or questions I will be glad to help. If you need any additional assistance don’t hesitate to ask.
If you want to find the count of your filtered or non filtered rows, you could use GetNAProperty method, without using a Loop through all rows in the grid. You could use both UltraGrid`s properties which conatains required values. For example:
SwfWindow("Form1").SwfTable("ultraGrid1").GetNAProperty("Rows.FilteredInRowCount")
and
SwfWindow("Form1").SwfTable("ultraGrid1").GetNAProperty("Rows.FilteredInNonGroupByRowCount")