Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using a array to retrieve data
Message
From
19/05/1998 16:25:09
Christian Bellavance
Université du Québec à Hull
Hull, Quebec, Canada
 
 
To
All
General information
Forum:
Visual Basic
Category:
ActiveX controls
Title:
Using a array to retrieve data
Miscellaneous
Thread ID:
00100400
Message ID:
00100400
Views:
102
Hi!!

I'm trying to create an object that retrieves the data from a SQL Server 6.5 to VB5. The function is call RetrieveData and it has two parameter. SQL$ which is the sql statement which the function has to execute and an variant array in wchich I want to send the data back. The function return True or False if it worked or not.

Here the declaration:
Public Function RetrieveData(ByVal Sql As String, ByRef Data() as variant) as boolean

The function do a redim on the array when it knows the number of record and the number of columns and it puts the record in the array.

The problem is that I'm unabled to read the array in the function who call the RetrieveData because I'm getting the error that says "Argument ByRef incompatible"

It probably because the array as change in the proccess but my question is How can i pass that array between function?
Next
Reply
Map
View

Click here to load this message in the networking platform