I have a command button that I want to enable and disable using code. I have
tried this:
ActiveSheet.Shapes("PrintJour").Enabled = True
Without any luck. Can anyone guide me?
The Doctor
Peter T - 19 Mar 2008 13:45 GMT
Dim bEnable As Boolean
bEnable = False ' true to enable
ActiveSheet.OLEObjects("CommandButton1").Object.Enabled = bEnable
Regards,
Peter T
> I have a command button that I want to enable and disable using code. I have
> tried this:
[quoted text clipped - 4 lines]
>
> The Doctor
Dave Peterson - 19 Mar 2008 13:55 GMT
Another one:
Worksheets("sheet1").CommandButton1.Enabled = False
> I have a command button that I want to enable and disable using code. I have
> tried this:
[quoted text clipped - 4 lines]
>
> The Doctor

Signature
Dave Peterson