Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
WebTable Name keeps changing
#1
Solved: 10 Years, 9 Months, 4 Weeks ago
Hi All ....
Description: I have to write a script for clicking all the links in a webtable in a flow,the flow consist of 2 tables,I used For loop to click all the links one by one...the problem is when I click the first Link in first table ..it leads to the second table..and when i click on the second link in first table it leads to second table(but now the table name is different)
1st table(1st link)------>2nd table(1st link)
here i should click all the links in 2 table and goes
back to first table
1st table(2nd link)------>2nd table(1st link) now the webtable name of 2nd
is changed...so i am getting the error webtable
name not found in repository
I think you guys have understood what is my problem..Can any one help to find out a solution for it please..Please check with the below code......I have attached the same code as attachment too

Code:
RowCount = Browser("Browser").Page("Page").WebTable("Convertible").RowCount
ColumnCount = Browser("Browser").Page("Page").WebTable("Convertible").ColumnCount(1)

For a = 1 To RowCount
    
    For b = 1 To ColumnCount
        
        Set cfsmake= Browser("Browser").Page("Page").WebTable("Convertible").ChildItem(a,b,"Link",0)
            cfsmake.Click
        R1 = Browser("Browser").Page("Page").WebTable("Aston Martin").RowCount
        C1 = Browser("Browser").Page("Page").WebTable("Aston Martin").ColumnCount(1)
            
        For a1 = 1 To R1
            
            For b1 = 1 To C1
                
                cellData = Browser("Browser").Page("Page").WebTable("Aston Martin").GetCellData(a1,b1)
                If cellData = Browser("Browser").Page("Page").WebTable("Aston Martin").GetCellData(R1,C1-1) Then
                      Browser("Browser").Page("Page").Link("Home").Click
                Else     
                    Set cfsmake= Browser("Browser").Page("Page").WebTable("Aston Martin").ChildItem( a1 , b1 ,"Link",0)
                          cfsmake.Click
                        Browser("Browser").Back
                         b1 = b1+1
                 End If
             Next
        Next
    Next
Next

Please do the need full


Attached Files
.txt   script.txt (Size: 1.02 KB / Downloads: 77)
Reply


Messages In This Thread
WebTable Name keeps changing - by SmithaQTP - 03-06-2008, 07:03 PM
RE: WebTable Name keeps changing - by Ankur - 03-11-2008, 01:37 PM
RE: WebTable Name keeps changing - by SmithaQTP - 03-11-2008, 03:37 PM
RE: WebTable Name keeps changing - by Ankur - 03-11-2008, 03:41 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Page element keep changing chong67 4 4,337 11-08-2016, 09:17 PM
Last Post: Paul Rammone
  Changing QTP Class praveendasika 1 2,809 07-13-2012, 07:35 AM
Last Post: ravi.gajul
  Objects keep changing names janriis 2 3,447 09-28-2010, 12:54 PM
Last Post: janriis
  Changing URL capf 2 7,069 09-14-2010, 07:31 PM
Last Post: bfakruddin
  Changing ONE item in a repository mrmarkus48 0 1,735 04-24-2009, 01:06 AM
Last Post: mrmarkus48

Forum Jump:


Users browsing this thread: 1 Guest(s)