A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data.
Hi Ossie.
Can you let me know how I can get this working again? Or start over?
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I have an Excel 2010 workbook that every timed I open it, it automatically numbers itself - this has stopped working.
In cell K3, the number is 4881, so the next time I open the file I would like the number to be 4882, (the way it used to be)
Here is the code I am using:
Private Sub Workbook_Open()
Sheets("ORDER").Range("K3").Value = Sheets("ORDER").Range("K3").Value + 1
End Sub
End Sub
Can you please help me to get it working again?
A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data.
Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.
Hi Ossie.
Can you let me know how I can get this working again? Or start over?
Thank you Ossie.
It did come back True. I do not have any other workbooks open...
Some stuff to check.
Open the VBA editor
Open the Immediate window (Ctrl and G)
Type the following command into the Immediate Window and press Enter and see if it returns True
? Application.EnableEvents
If it returns False then perhaps you are using another workbook prior to opening the problem workbook and some code in it is disabling events and no code to re-enable events.
If the above returns False then type the following into the Immediate window and press Enter and then save and close the workbook and re-open and see if the number is incremented.
Application.EnableEvents = True
Ensure that the problem workbook is saved prior to closing it otherwise the updated number is not saved.
Holding the Shift key while opening the workbook stops the workbook open event from running.