Monday, October 18, 2010

notes

We will make our very *first* program!
adding program

what did I do?
Drew the GUI. Changed the fornt size and other properties of the controls. Changed the name property of a bunch of controls.

at run time, to get access to the properties of a control, we use the . operator

Private Sub cmdCalculate_Click()
    Dim x As Integer
    Dim y As Integer
    Dim z As Integer
    x = txtFirstNumber.Text
    y = txtSecondNumber.Text
    z = x + y
    lblOutput.Caption = z
End Sub

HW: Take as input the Title, FirstName and LastName. Calculate FullName and Display it.

VB or VBA programming


Excel
Relative references, Absolute references, Mixed References
A1 style vs R1C1 style

Relative references change when you copy them

Absolute references stay put
Mixed References: row absolute, column relative
OR
column absolute, row relative


R1C1 stands for row 1 column 1

No comments:

Post a Comment