Lesson#4 Properties, Methods and Parameters Flashcards
What are properties?
The characteristics or attributes that describe an object.
i.e. The Looks and Behaviours
What are methods?
The actions you carry out with, or on, an object.
What 2 things can you do when working with properties?
- Specify (write) the properties value.
2. Read the properties current value.
What 2 things can you do when working with methods?
- Carry out the action method.
2. Create a new object or return a value.
What can you do with parameters or values?
Write the new the value of a property or further specify the behaviour of a property/method.
What happens if you omit an optional parameter?
VBA uses it’s default value.
What is the structure of a VBA statement that works with method parameters?
Object.Method ParameterList
How do you separate a parameter name from it’s value?
:=
How do you structure a VBA statement when you are looking to use a method to create a new object or value?
Wrap the parameter list within parentheses instead of using a space.
What is the structure of a VBA statement that works with property parameters?
Object.Property(ParameterList)
What is the structure of a VBA statement that specifies a new property value?
Object.Property = NewPropertyValue
What are the 2 main rules to consider when specifying a new property value?
- You usually specify a single value.
2. You use the assignment operator. (=)
How do you separate Parameters in a list?
Comma and a space.