How can I retrieve the data from ultrawingrid?
Firstly i added the ultrawingrid object to the script (“UltraGrid1Net()”). then
Dim MyTable As UltraGridTestObject
Dim Row As Integer
For Row = 0 To MyTable.GetRowCount() - 1
Dim Col As Integer
For Col = 0 To MyTable.GetColumnCount() - 1
msgbox("Value at cell {0}, {1}, {2}: {3}", ("Row"), ("Col"), ("is"), MyTable.GetCell(Row, Col)))
Next Col
Next Row
I got the above code from net and I modified according to my requirement, when I’m trying to compile the above code it is giving me the following error:
“Type ‘UltraGridTestObject’ is not defined”
Pls let me know is ‘UltraGridTestObject’ is right to use for ultrawingrid or let me know the appropriate object to use.
Another way to do this will be to use the GetData method of the grid test object, here is how:
Dim MyTable As Infragistics.RFT.NetTestObjects.UltraGridTestObject = UltraGrid1Table()
Dim data As Infragistics.RFT.Shared.Values.Array2DValue = MyTable.GetData(Nothing)
Dim outputText As String
For Row = 0 To data.RowCount - 1
For Col = 0 To data.CellCount - 1
outputText = String.Format("Value at cell {0}, {1}, is: {2}", Row, Col, data.GetValue(Row, Col))
LogTestResult(outputText, True)
Hi Ammar,
when i'm using the above code i'm getting "Type 'Infragistics.RFT.NetTestObjects.UltraGridTestObject'
not declared" error.
I need to import any header files??
Rekha.