Hi,
I have a function that must fill an array that is passed to it with values. Online help states that
Dim ChildRow(30) As Integer
Call ChildArray(RowForm, ChildRow())
...
Public Sub ChildArray(ByRef RowForm As String, ByRef ChildRow() As Integer)
The procedure itself seems to compile normally, but the line that calls it throws a compilation error: "Type mismatch: array or user-defined type expected"... which also suggests the possibility of array parameters, only that I'm not using it right.
Thanks.
I have a function that must fill an array that is passed to it with values. Online help states that
, from which I concluded that using arrays as parameters is possible. So I have the following code:The arglist argument has the following syntax and parts:
[Optional] [ByVal | ByRef] [ParamArray] varname[[!]( )[/!]] [As type] [= defaultvalue]
Dim ChildRow(30) As Integer
Call ChildArray(RowForm, ChildRow())
...
Public Sub ChildArray(ByRef RowForm As String, ByRef ChildRow() As Integer)
The procedure itself seems to compile normally, but the line that calls it throws a compilation error: "Type mismatch: array or user-defined type expected"... which also suggests the possibility of array parameters, only that I'm not using it right.
Thanks.