Micro Focus QTP (UFT) Forums
How to remove space between webelements - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners)
+--- Thread: How to remove space between webelements (/Thread-How-to-remove-space-between-webelements)



How to remove space between webelements - silpavinod - 10-10-2012

consider that we are having 6 Webelements
Ex: 1.a
2.Space
3.b
4.Space
5.c
6. space

From the above Ex how can i remove that space values and click on b


RE: How to remove space between webelements - harishshenoy - 10-11-2012

Hi ,

you need to use your own logic for avoiding 'space' web elements.

like :

Code:
for i = 1 to 6
  if browser().page().webelement("space").exist then
    next
  end if
  browser().page().webelement("property").click
next

Here for 'i' loop u have to use the child Item count or need to store the properties of the 'web element' in an array and then using descriptive programming u can use them.

Thanks,
Harish


RE: How to remove space between webelements - silpavinod - 10-11-2012

ok fine thanks