QTP Fundamental - Part One
QTP Fundamental - Part One - Example 1: Validate if a webtable exist boolExist = Browser(…).page(…).webtable(…).exist - Example 2 : To Find number of rows and columns in a web table intRowCnt=Browser("Google").Page("title:=.*").WebTable(“name:= TTable").RowCount For r=1 to intRowCnt ‘’ This will loop through each row and tell count of column in each row. intColCnt=Browser("Google").Page("title:=.*").WebTable(“name:=TTable").ColumnCount(r) MsgBox intColCnt Next - Example 3: How to get data in a particular cell in the data table strData= Browser("Google").Page("title:=.*").WebTable(“name:=TTable").GetCellData(r,c) Where r = row number and c = column number - Example 4: Using childObject method to find objects of a particular type within a webtable Public Function func_findObjectinaWebTable(strObjType) Set objDesc=Description.Create objDesc("micclass").value=strobjType set objChild=Browser("Goog...