Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
QTP throws error on web elements when Descriptive programing used.
#2
Not Solved
Hi Ramesh,

Try this script once, please let me know if you get any errors.
Code:
set desc=Description.create()
desc("micclass").value="WebTable"
desc("name").value="Add New Work"    ' Edit here if name is different
'Add more values incase if exists for the table

Set WebEdits=Browser("title:=Works Information Management System").page("title:=Works Information Management System").ChildObjects(desc)
rCount=WebEdits(0).rowCount
'WebEdits(0) here 0 is used to access the first webtable, change it if  different table
For r=1 To rCount-1
    cCount=WebEdits(0).columnCount(r)
    For c=1 To cCount-1
        oCount=WebEdits(0).ChildItemCount(r,c,"Link")
        obj=1 To oCount-1
        If (StrComp(WebEdits(0).ChildItem(r,c,"Link",obj).GetROProperty("innertext"),"Cost Estimate")=0) Then
            WebEdits(0).ChildItem(r,c,"Link",obj).Click
        End If
    Next
Next
Reply


Messages In This Thread
RE: QTP throws error on web elements when Descriptive programing used. - by KavitaPriyaCR - 11-19-2010, 11:42 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Descriptive programing kedala 1 2,733 10-04-2016, 09:25 PM
Last Post: venkatesh9032
Smile find out of spelling error in Web application deveshbhatt29 1 2,207 01-10-2014, 05:10 PM
Last Post: Maheep_bhambri
  Getting an 'Error in XML document' Error when submitting web services XML luckyexpert 0 3,118 08-20-2013, 10:23 PM
Last Post: luckyexpert
  Web Table Descriptive Language karraaruna 3 3,456 07-04-2013, 08:06 PM
Last Post: karraaruna
  Web Elements DL karraaruna 3 3,204 06-06-2013, 10:05 AM
Last Post: vinod123

Forum Jump:


Users browsing this thread: 6 Guest(s)