Sign in to follow this  
Followers 0
Roland S.

Best case using ByRef

2 posts in this topic

Hello Forum,

i have some stupid question: When is the best case to use the keyword ByRef for variables?

Becaus i am not shure every time, i have to ask this question to all the people here.

regards

Roland

Share this post


Link to post
Share on other sites



it's used in function parametres

1) when you need change value of parameter inside func and return this changed value back through th

at parameter variable2

2) when you pass array as function parameter - in this case there isn't done copy of all array to local variable --> this is for speed optimalization

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0