Answer Posted / priya
If you want to pass the value of the variable, use the
ByVal syntax. By passing the value of the variable instead
of a reference to the variable, any changes to the variable
made by code in the subroutine or function will not be
passed back to the main code. This is the default passing
mechanism when you don’t decorate the parameters by using
ByVal or ByRef.
If you want to change the value of the variable in the
subroutine or function and pass the revised value back to
the main code, use the ByRef syntax. This passes the
reference to the variable and allows its value to be
changed and passed back to the main code.
Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
What is difference between constants and read-only?
What is difference between function and method in c#?
What is a property in c#?
What is the namespace for datatable in c#?
List the fundamental oop concepts?
What is null character in string?
Is null empty or whitespace c#?
i want the csharp questions&answeres
Ho we can see assembly information?
What is literal control
What is private virtual in C#?
What are the various components in crystal reports?
What is the signature of a method?
What do you mean by for each loop?
List down the reason behind the usage of c# language.