|
-
June 15th, 2001, 04:20 PM
#1
Passing an array as a parameter in a subroutine
Hi,
Can someone please show me how I can pass an array as a parameter in a subroutine or function.
Thanks,
RF
-
June 15th, 2001, 04:26 PM
#2
Re: Passing an array as a parameter in a subroutine
Let's say you have a function that calculates an average, you would define the function like this...
Public Function Average(Array()) As Long
Be sure you put those parentheses where necessary. When you make a call to that function, you'll want to send it an array of numbers that are to be averaged. If that array is X() then a call to the function would go...
Text1.Text = Average(X)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|