Hi there,
My first day trying to work out visual Basic!
I've got a number of objects laid out on my userform, but some of them need to be invisible before a button in pressed.
I need it to hide the labels, other buttons etc on startup everytime the workbook is opened.
I've tried the following code just in the workbook-open function but it isn't working? is it because I need to reference the userform in someway?
Private Sub Workbook_Open()
ActiveWorkbook.Sheets("working").Activate
Range("c3:c5").Value = "NA"
Range("c8:c12").Value = "NA"
Range("c15:c19").Value = "NA"
Range("c25:c27").Value = "NA"
the above all work fine
label16.visible = false does not work
End Sub
How do I reference the userform?
Thanks!
My first day trying to work out visual Basic!
I've got a number of objects laid out on my userform, but some of them need to be invisible before a button in pressed.
I need it to hide the labels, other buttons etc on startup everytime the workbook is opened.
I've tried the following code just in the workbook-open function but it isn't working? is it because I need to reference the userform in someway?
Private Sub Workbook_Open()
ActiveWorkbook.Sheets("working").Activate
Range("c3:c5").Value = "NA"
Range("c8:c12").Value = "NA"
Range("c15:c19").Value = "NA"
Range("c25:c27").Value = "NA"
the above all work fine
label16.visible = false does not work
End Sub
How do I reference the userform?
Thanks!