Please show what you have already tried when asking a question.
Re: Changing property value using "if" statements
Posted 24 December 2013 - 09:40 AM
Give a man a fish and he eats for a day, teach a man to fish and he eats for a lifetime.
Which is my way of saying: "Have you read about the ref keyword? What does it do and what does it do for you? If you comprehend it, then you should be able to decide if you need it or not.
Have you just tried playing with your code? Make multiple methods changing the property "Display". Have some them use the ref keyword, and have some of them not. What happens?
You have the tools in front of you to learn these things, without someone hand holding you, or being your free private tutor.
If after doing some experimenting and reading, you should have some questions about your *results* please jump back on and ask them. We are always happy to clear up misunderstanding, just not so quick to give you all the answers so you don't have to do any work to learn them on your own.