Passa al contenuto principale

tdNext

Structure

tdNext(iDataSet)

Type

Procedure

Description

This function will move one of three temporary datasets to its next record.

Parameters: 1

iDataSet=# of dataset, must be 1-10. IndySoft provides 10 datasets that can be accessed through 'td*' custom script functions.

Example

if tdDoSQLRecords(1, 'SELECT COMPANY_NAME FROM COMPANY ORDER BY COMPANY_NAME') then

tdFirst(1)

while (tdEOF(1) = '0')

sCompanyName = tdFieldbyNameAsString(1, 'COMPANY_NAME')

iCount = 0

if tdDoSQLRecords(2, 'SELECT COUNT(*) AS COUNTER FROM GAGES WHERE COMPANY = '' & sCompanyName & ''') then

iCount = tdFieldbyNameAsInteger(2, 'COUNTER')

End If

ShowMessage('Company: ' & sCompanyName & Chr(13) &

'Gage Count: ' & IntToStr(iCount))

tdNext(1)

End While

End If |