Sample Code
Innovative Information Management            

SAMPLE CODE : Searching and Then displaying a list of results

The following code is all that is needed to create a picklist, or to summarize the results of a search.

 

' Construct the BASIS find Command - BASIS Objects are highlighted in red.

sCommand = "FIND EMPLOYEE WHERE EMPLOYEE_NAME EQ ' " & _
sName & " ' "

If objResultSets.ExecuteQuery(sCommand) Then ‘ A Result Set has been created

' We must identify which fields we want data for
objRecordData.addField "EMPLOYEE.EMPLOYEE_NAME"
objRecordData.addField "EMPLOYEE.EMPLOYEE_NUMBER"

For iMember = 1 To objResultsSets.SetMembers(0)

If objRecordData.GetRecord(0,iMember) Then ' Retrieve a record

GridEmployees.AddItem & _ objRecordData.FieldValue("EMPLOYEE_NAME") & objRecordData.FieldValue("EMPLOYEE_NUMBER")

End If

Next

End If ‘ Result Set created

End Sub

. . .
Home
Bio
Contact Info
Services
Consulting
Maintenance
and Support

Training
Products
BASIS
RAD for BASIS
BWX
MySQL
Developer's Corner
Tech Tips
Links
CANBUG
Home Teradocs Systems Inc. © 2001-2005 Top