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 meant by desktop application?
How is a loop recorder monitored?
What is byte c#?
Is c# pass by value?
List the fundamental oop concepts?
Which is the best language for desktop application?
How do I create a multilanguage, single-file assembly?
What are handlers in c#?
Why use a singleton instead of static methods?
Explain the types of assemblies in .net?
Why are mutable structs evil?
Describe two uses of the “using” statement during the operation of c#?
What is string empty?
i want the csharp questions&answeres
What is the file extension for c#?