rp_data::getorowsitem

This is used to retrieve items from the oRows property. This is necessary due to issues with visual basic accessing the oRows property (Public)

o.getorowsitem( tnItem)

Return Value

Object - The oRows object item

Parameters

tnItem
The integer item number of the oRows item you want returned

Remarks

This method is only required by users who are using the Object within a development
environment other than Visual Foxpro. For some reason direct access of the oRows
property causes problems in Visual Basic. Hence this method was added to return
rows from the oRows proerty.

Example

oRow = o.GetoRowsItem(1)

This would return an object where the object is the same as o.oRows.Item(1)

The following is an example of how this would be used in Visual Basic code.

Private Sub Command1_Click()

   Dim nRowCount As Long
   Dim oITObject  As Object
   Dim ln As Integer
   Dim lni As Integer
   Dim orow As Object

   ' Create object .  In this case InfoTodays ITRDS product
   Set oITObject = CreateObject("ITRDS.RP_CLIENT")
   lresult = oITObject.SetConnection("LOCAL")
   lresult = oITObject.SetSystem("TEST")
   lresult = oITObject.OTABLE.SetTable("CUSTOMER")

   nRowCount = oITObject.OTABLE.Query("select * where account = '814455'", "", 31)

   ln = oITObject.OTABLE.orows.Count

   For lni = 1 To ln
        Set orow = oITObject.OTABLE.GetoRowsItem(lni)
        account = orow.account
   Next lni

End Sub

See also:

Class rp_data


Last Updated: 23/11/2005