First, ByVal and ByRef mean "by value" and "by reference". Since everything
you do on a computer is in memory, something things just want a "pointer" to
the memory location where you data is. Some want the actual data itself.
There are advantages to both.
A ByVal parameter makes a copy of the value, whereas ByRef passes the
pointer to the memory address. Therefore, if a parameter is passed ByRef and
you change it's value in your function, it changes for the caller too -
because you were both pointing at the same memory location.
If a parameter is passed in ByVal, then you have a copy of it. If you make
changes inside your function, then it leaves the orginal alone - because you
have a seperate copy.
"sender" is a generic reference to which object kicked off the event that
you are in. You may just want to know, who fired the event. "EventArgs" are
arguments that go along with that event. Those both become more meaningful
when you use an object like a treeview - where the sender is the node that
was clicked, etc..
"Maurice Walmsley" <com> wrote in message