Exam coming up, I have questions I need help answering.
Posted on 2008-11-11
I have an upcoming exam and I don't have access to my professor and I have questions that the book is not clarifying for me. The book that the class is using is Murach's Visual Basic 2008.
iI will list the questions will by numbers. I understand that there are alot of questions here but I really need a good grade on this exam and these are the areas that I am still unsure of. Some of the questions, I have tried to answer and I posted a comment in (), it my guess is correct could you annotate so. If not could you help me get on base.
I am taking the exam tomorrow at 11. I have been buried in this book for a couple of days now and I need help. I am using this site as a last resort. I figured individuals on here are much more proficient than myself so I mine as well ask the experts.
I want to thank anyone in advance that is willing to answer any of these questions for me. God Bless and Happy Veterans Day. I myself am an "Iraq Veteran" in 2003.3. When and how to pass arguments by reference and by value?
- The book says this. I dont understand what it is saying at all:
Arguments are passed by value. Because of that, the procedure can change the value of the parameter without affecting the value of he variable in the calling procedure.
In some cases, though, you will want to be able to change the value of the variable in the calling procedure from the called procedure. To do that, you can pass the argument by reference.
When you call the procedure, a reference to that variable is passed to the procedure. As a result, if that called procedure changes the value of the parameter, it also changes the value of the variable in the calling procure.
If you pas a reference type by reference, you still cant change its value (the reference), but you can change the values of members of the object it refers to. In contras if you pass a reference type by value, you can change both its value and the values of its members.
Can you explain this in laymen terms?