Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Sort Order Check
#3
Not Solved
Code:
Set oDesc=Description.Create()
oDesc("micclass").value = "WebElement"
oDesc("class").Value = "order_details_main_boxes"
Set sLinks = Browser("Browser").Page("Page").ChildObjects(oDesc)
sLinkCount = sLinks.Count
PRINT "sLinkCount " &sLinkCount
For i = 0 to sLinkCount - 1
iName= sLinks(i).GetROProperty("innertext")
iOrderNumber =Left(iName, 7)
iDate = Right(Left(iName, 20), 10)
aSort(i) = iOrderNumber
PRINT "AppSort "&aSort(i)
Next

Public Function fnSort()
   For j = 0 To sLinkCount - 1
    For k = j + 1 To sLinkCount - 1
        If aSort(j) > aSort(k) Then
            sTemp = aSort(j)
            aSort(j) = aSort(k)
            aSort(k) = sTemp
        End If
    Next
Next
End Function

fnSort()
For j=sLinkCount - 1 to 0 Step - 1
    sDescArr(j) = aSort(j)
    PRINT "sDesc " &sDescArr(j)
Next

fnSort()
For j=0 to sLinkCount - 1
    sAscArr(j) = aSort(j)
PRINT "sAsc " &sAscArr(j)
Next


I have got the code to check the sort logic but failed to check the validation....

need some help in this regard....i need to compare application order sort and the sort which i got from the logic i used above....
Reply


Messages In This Thread
Sort Order Check - by automation2012 - 03-06-2013, 12:00 PM
RE: Sort Order Check - by automation2012 - 03-07-2013, 04:15 PM
RE: Sort Order Check - by automation2012 - 03-26-2013, 02:54 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Should I download every patch in order to UFT recognize the Chrome and FireFox browse jesusisaac 6 5,385 08-25-2016, 05:03 PM
Last Post: Ankesh
  Get numbers inside all webelements in webtable and sort them pradeep537 1 2,850 08-04-2016, 01:24 AM
Last Post: Ankur
  Automating SAP Sales Order Dwarak Calayampundi 0 1,738 06-09-2016, 09:28 AM
Last Post: Dwarak Calayampundi
  Sort multidimensional array SBsteven 8 9,096 03-14-2014, 02:49 PM
Last Post: anuj.bajaj
  sort two dimensional array. venkatesh9032 0 1,835 03-06-2014, 02:47 PM
Last Post: venkatesh9032

Forum Jump:


Users browsing this thread: 1 Guest(s)