mercredi 25 février 2015

QTP - Checking dynamic pages





I'm trying to check if a value is contained in the innertext of a webelement but I'm having a little problem: frames seem to change at every refresh of the pages.



These are the steps I've recorded:



Browser("SystemPage").Page("SystemP").Frame("dme2_header").Image("Gestione Anagrafiche").Click Browser("SystemPage").Page("SystemP").Frame("dme2_appl").WebEdit("pdrBean.pdrPod").Set parameter("POD") Browser("SystemPage").Page("SystemP").Frame("dme2_appl").WebButton("Cerca").Click Browser("SystemPage").Page("SystemP").Frame("dme2_appl_2").Image("show_files").Click Browser("SystemPage").Page("SystemP").Frame("dme2_appl_6").Image("Lente").Click cctype = Browser("SystemPage").Page("SystemP").Frame("dme2_appl_7").WebElement("arrow_down").GetROProperty("innertext") DataAct = Browser("SystemPage").Page("SystemP").Frame("dme2_appl_7").WebElement("arrow_down_2").GetROProperty("innertext") Browser("SystemPage").Page("SystemP").Frame("dme2_header").Image("Gestione Anagrafiche").Click



The frames "dme2_appl6" and "dme2_appl7" changes at every refresh of the two pages.

The question is simple: how can I rewrite these two actions to make them universal?


Aucun commentaire:

Enregistrer un commentaire