Powered by: Dharamveer Saxena

Thursday, November 5, 2009

TestComplete : To access column of Infragistics Grid using its index

To access column of Infragistics Grid using its index:

------------------------

function get_column(grid, columnindex)
set get_column = grid.DisplayLayout.Bands.Item(0).Columns.Item(columnindex)
end Function

---------------------

You can use this function as bellow to get the header caption of a particular column

sub main
MsgBox( get_column(DIGridControl,4).Header.get_Caption.ToString)
end sub

No comments:

Post a Comment