ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   ?? Create a Public SUB with an array as parameter. ?? (https://www.excelbanter.com/excel-programming/393987-create-public-sub-array-parameter.html)

Barb

?? Create a Public SUB with an array as parameter. ??
 

I created a class

public sub FindInIt(myArray() as double)
...
€¦
End sub

When Im creating an object to call that sub ,
Obj.FindInIt(ThisismyArray) then

I receive an error message that says €¦. Compile error expected =

like if it was a function. My question is can I pass an array by reference?

Thanks.


NickHK

?? Create a Public SUB with an array as parameter. ??
 
Read the VBA help on the Call statement.

NickHK

"Barb" wrote in message
...

I created a class

public sub FindInIt(myArray() as double)
..
.
End sub

When I'm creating an object to call that sub ,
Obj.FindInIt(ThisismyArray) then

I receive an error message that says .. Compile error expected =

like if it was a function. My question is can I pass an array by

reference?

Thanks.





All times are GMT +1. The time now is 01:34 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com