I'm new to VBA and I'm unable to find answer to this. I have ActiveX Button on one sheet. I'm also creating new sheets is same workbook. Problem is that button is appearing on all of those worksheets. I would like that button to appear only on one worksheet, so it will not be on other worksheets that I create with VBA.
Code in separate module:
Option Explicit
Sub copying()
Worksheets(1).Copy After:=Worksheets(Worksheets.Count)
Worksheets(2).Activate
Worksheets(2).Name = "Test"
End Sub
Code for button that is calling copying function:
Option Explicit
Private Sub CommandButton1_Click()
Call copying
End Sub
Button is appearing on new worksheet that is created.
Thank you.