In my code, I have a function, which returns a single row of data from a database. It returns the data using a Structure
so I can return more than 1 data.
For example:
Public Structure structure_name
Public column1 as integer
Public column2 as string
Public column3 as string
End Structure
Function function_name() As structure_name
Dim single_row_structure as structure_name
'get single row from database
'assign single row values to attributes of Structure
single_row_strucure.column1 = dbcol1
single_row_strucure.column2 = dbcol2
single_row_strucure.column3 = dbcol3
return single_row_strucure
End Function
This works fine for a single row. My question is, how do I get a function to return more than 1 row of data?