Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Get value of a List view item
#2
Solved: 10 Years, 10 Months, 1 Week ago
The Below program might solve your problem
a brief explanation of the below program

1) get total no of columns --------->(ColumnCount)
2) get total no rows in the wilnlist view------->(GetItemsCount)
3) retrieve the desired value from the column------>(GetSubItem(i,C_Name))


Code:
With Dialog("Text:=Windows Task Manager")
    .wintab("nativeclass:=SysTabControl32").Select "Processes"
    
R_Count=.WinListView("nativeclass:=SysListView32").GetItemsCount
'msgbox ("Total no of rows"&R_Count)

C_Count=.WinListView("nativeclass:=SysListView32").ColumnCount
'msgbox ("Total no of columns:  "&C_Count)

For i=0 to R_Count-1
    For j=0 to C_Count-1
        C_Name=.WinListView("nativeclass:=SysListView32").GetColumnHeader(j)
        t= .WinListView("nativeclass:=SysListView32").GetSubItem(i,C_Name)
        
    Next
Next
End With

i hope the above program will help you
Reply


Messages In This Thread
Get value of a List view item - by qtpbegin - 07-19-2012, 06:52 PM
RE: Get value of a List view item - by sree.85 - 07-19-2012, 11:52 PM
RE: Get value of a List view item - by qtpbegin - 07-20-2012, 11:36 AM
RE: Get value of a List view item - by Deepak_QTP - 08-08-2012, 04:58 PM
RE: Get value of a List view item - by sree.85 - 07-26-2012, 06:31 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Cannot identify the specified item Beginner 0 2,358 06-22-2017, 04:55 PM
Last Post: Beginner
  SwfTree View Validation in UFT YogeshCallappa 0 1,959 10-28-2016, 01:26 PM
Last Post: YogeshCallappa
  WinListView set item command Shahino007 0 2,551 10-06-2015, 03:57 PM
Last Post: Shahino007
  Objects are being recognized as "Windows for Menu item list (Browser-firefox, UFT 12) akhandesh 0 2,392 05-27-2015, 06:29 PM
Last Post: akhandesh
Question Outside View Terminal Emulator testing joncfrazier 0 3,217 12-04-2013, 10:47 PM
Last Post: joncfrazier

Forum Jump:


Users browsing this thread: 1 Guest(s)