SOLVED

VBA Code - Open Workbook Button Hidden

Copper Contributor

Hello, 

 

TIA! I'm stumped, I'm trying to revive a macro book after the creator left the company. The workbook has an expiration code attached to it and when I extend the dates, the macro doesn't update with the new dates so I'm missing something. 

 

With the extended date, upon opening the workbook, a menu button should appear is (3,15), but does not.. 

 

I'm attaching the Workbook Open code intially.

 

CptWilson11_0-1715220059149.png

 

4 Replies

@CptWilson11 

Did you edit the dates in Workbook_Open to future dates, then immediately save the workbook?

@Hans Vogelaar yes, I have. Which then doesn’t bring up the prompt, so I believe that works.

 

But the code should make a button visible if it’s not “expired” but it is not. This is my hang up I believe. 

best response confirmed by CptWilson11 (Copper Contributor)
Solution

@CptWilson11 

Insert the following line below   Private Sub Workbook_Open():

 

    Sheets("Instructions").Shapes("menuButton").Visible = True

That did it! Thank you so much!
1 best response

Accepted Solutions
best response confirmed by CptWilson11 (Copper Contributor)
Solution

@CptWilson11 

Insert the following line below   Private Sub Workbook_Open():

 

    Sheets("Instructions").Shapes("menuButton").Visible = True

View solution in original post