Step 1. Input Form - Set the Stored
Data Values Private Sub
Form_Load()
' you could put code here that
executes when the first program starts
' set the values of the stored
data variables here
' ready to use later on
'example
lawnSeedCoverage = 30
lawnSeedinBag = 1000
etc…..
End Sub

Step 2. Input Form - Get the
users input
Private Sub cmdSubmit_Click()
' the user clicks the command
button
' get the values from the
input textboxes here
'example: the two lines
below get the values from two textboxes
rectLawnLength = txtRectLawnLength.Text
rectLawnWidth = txtRectLawnWidth.Text
etc…..
calculate ‘run the
calculate sub routine
End Sub

Step 3. Input Form - carry out the
calculations
Private Sub calculate()
'you can put code in that does
all the calculations
'example: the two lines below
calculate an area and seed amount
rectLawnArea = rectLawnLength * rectLawnWidth
rectLawnSeedAmount = rectLawnArea * lawnSeedCoverage
etc…..
Me.Hide 'hide the input
form
Load Form2 'load
and show the output form
End Sub

|