Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Syntax Errors
#1
Solved: 10 Years, 8 Months, 4 Weeks ago
Hi ,the below code is giving syntax errors like "Expected Statement","expectd end of statement".but I feel the code is correct.can anyone please double check the code and correct me if am wrong.please solve this ASAP.
Code:
If BrowserObject.Webtable("micclass:=WebTable","html id:="&strWebtableID).exist  Then
                intColCount = BrowserObject.Webtable("micclass:=WebTable","html id:="&strWebtableID).columncount
                msgbox intcolcount
                Set oDesc = Description.Create()
                oDesc("micclass").Value = "Link"
                Dim myarray1()
                Set EditCollection = BrowserObject.Webtable("micclass:=WebTable","html id:="&strWebtableID).ChildObjects(oDesc)
                NumberOfEdits = EditCollection.Count
                ReDim myarray1(NumberOfEdits)
                If  NumberOfEdits <> 0 Then
                        Reporter.ReportEvent micDone,"Child Objects","No " &strObjClass& "object present in the current Page"
                        'Retrieving the values before Reset button clicked
                        For i = 0 To intColCount
                                If (EditCollection(i).GetROProperty("micclass") = strObjClass) Then
                                                EditCollection(i).click
                                                strFirstRow = BrowserObject.Webtable("micclass:=WebTable","html id:="&strWebtableID).GetCellData(2,i)
                                                strSecondRow = BrowserObject.Webtable("micclass:=WebTable","html id:="&strWebtableID).GetCellData(3,i)
                                                intComarision = strComp(strFirstRow,strFirstRow,1)
                                                
                                                If intComarision = "0" then
                                                    Reporter.Reportevent micPass,"Sorting","Values are Eqaul"
    '                                                
                                                        Do
                                                            j = 2
                                                            strFirstRow = BrowserObject.Webtable("micclass:=WebTable","html id:="&strWebtableID).GetCellData(J,i)
                                                            strSecondRow = BrowserObject.Webtable("micclass:=WebTable","html id:="&strWebtableID).GetCellData(j+1,i)
                                                            intComarision = strComp(strFirstRow,strFirstRow,1)
                                                            j =j+1
                                                        Loop until intComarision = "-1" or intComarision = "1"
                                                    else  If intComarision = -1" Then
                                                    Reporter.Reportevent micPass,"Sorting","Values sorted Ascending Order"
                                                    else if  intComarision = "1" Then
                                                    Reporter.Reportevent micPass,"Sorting","Values sorted Descending Order"
                                                    else
                                                    Reporter.Reportevent micDone,"Sorting","Comparision is failes"&intComarision
                                        End If
                                end if
                            Next
                end if
        end if
Reply
#2
Solved: 10 Years, 8 Months, 4 Weeks ago
Check for the End Ifs
Basanth
Give a fish to a man and you feed him for a day..Teach a man how to fish and you feed him for life.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  System Utility Syntax chita26 1 4,706 11-04-2014, 12:41 PM
Last Post: vinod123
  Syntax with descriptive programming martinshort 9 10,992 05-15-2013, 08:39 PM
Last Post: martinshort
  Getting multiple errors aminul 2 2,431 05-06-2013, 06:12 PM
Last Post: Saket
  Syntax of SystemUtil.Run vijay.gupta 6 77,456 08-21-2012, 04:57 PM
Last Post: vinod123
  Method definition syntax clarification lavsat 0 2,873 06-29-2012, 10:32 AM
Last Post: lavsat

Forum Jump:


Users browsing this thread: 2 Guest(s)