Forms - how do you get them to disappear?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,
Forms - how do you get them to disappear when
a) you click the cancel button
and
b) when you click the OK and the assigned macro has finished running

Please see the code attached for what I've tried already. "Printform" is the
name of the form. I've remmed out the lines that didn't work

'Private Sub Cancel_Click()
'Printform.Hide - didn't work
'Printform.Enabled = False - didn't work
'End Sub

Private Sub OK_Click()
If Printall.Value = True Then
Call PrintAllSheets
Exit Sub
Else
If print1.Value = True Then Call Printarea1
End If
'Printform.Hide - didn't work
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top