I have searched on the internet to see if I can find any references to these problems without success.
Occasionally, in Excel 2016 or Excel 2019 I open a macro-enabled workbook and discover all macros within the file have disappeared. This is despite enabling the macros when the workbook is opened. I determine there are no macros available by selecting Macros on the Developer Tab. No macros will appear in the macro dialog box. In addition, although a number of macros are linked to buttons within the file, I will try to use these and none will work.
If I save, close and re-open the workbook in either of these versions of Excel the macros still do not reappear. However, if I re-open the file in Excel 2010 the macros are available with all working as intended. If I save the file in Excel 2010, close it and then reopen it in Excel 2016 or Excel 2019 the macros will have reappeared.
Occasionally, and again in Excel 2016 or Excel 2019, when I open one of my more complex, macro-enabled files it will not open correctly and instead Excel indicates it is corrupted and requires repairs. I do not allow Excel to make the repairs and instead close the file, reboot Excel and try reopening the file. Again, Excel will indicate the file is corrupted and attempt repairs which are not accepted. However, if I switch to Excel 2010 and open the same file no problems are encountered with the file opening normally. Once it has opened, if I then save the file in Excel 2010 and close it, the file will then open normally in Excel 2016 or Excel 2019.
Might you have an answer to why this is happening?
Related
I have weird bug - then I open VBA Editor I can edit and create macros for sheets just fine, but then I try to edit macros for Workbook (create on_open event) I can't access ThisWorkbook tab in VBA Editor. Then I click it - nothing happens. What causing this problem? If I create new Excel workbook I can access this part with no problem (but that is not an option, since it would be to much work to move everything to new workbook).
EDIT: I turned off SOLVER add-in and the problem is gone. But I am still baffled why it was happening and how to avoid this problem in the future, since I sometimes need SOLVER add-in enabled.
EDIT 2: After writing desired routines for on_open and before_close events I restarted my Workbook to test it out. Events did not activated and I am locked from Workbook tab in VBA Editor again. Strangely everything worked fine then I tested it on older Excel version (MS Office 2013, version I am working with - MS Office 2016 version 1912 ) in other PC.
I'm using Excel 2010 and I have a .xla file with VBA macros, I edit the macros with the VBA editor, then save it. Later when I reopen the .xla file my changes are lost. On the internet I found other people with the same problem, e.g. MS-Excel VBA file (XLA) saving problem, but not solution.
please try to save it in the VBA-Editor. This ist what I have to do with xlam-files.
I make a lot of workbooks where there is no data in the workbooks themselves, but there are macros and forms attached. I generally format these in .xlsb or occasionally .xlsm file format, but I'm wondering if there is a format where there is no actual workbook attached. Just like a file you can open in Excel that will launch the macro?
It just seems pretty inefficient to include a blank workbook that I just autohide on load.
Depending on the version of Excel, when you load up Excel it automatically opens a Personal workbook which isn't visible.
Normally this is created when you record a macro and close all windows. It will then ask you to save it to the file. I would then set up shortcuts for the Macros.
I created an excel file where I added some buttons that I connected to different macros. I want to send this excel file to a collegue but when he opens this file the button gives an error:
Cannot run the macro "macro-name". The macro may not be available in this workbook or all macros may be disabled.
Is there a way to include or insert macro's inside the excel file?
[I use Microsoft Office Professional Plus 2010]
Found the answer myself, sorry:
Save as.. "Excel Macro-Enabled Workbook (*.xlsm)
I have developed a custom Excel 2010 Add-in and custom RibbonBar using VS 2010. When I install the custom Add-in for Excel, the RibbonBar is displayed or shown properly when Excel is opened. BUT, when I double-click the Excel file (.xlsx), the ribbon bar does not show on the Menu.
Please advise.
Few checks that may help
Disable all addins installed and then open a xlsx file by
enabling one addin in turn.
Start excel, create a new excel file
save, close and open it again to check if ribbon appears. If it work
fine for this, there could be some problem in file format or macro
attached with the file