A few days ago the macro buttons on spreadsheets we created stopped working.
It acted like the buttons weren't even there.
After I searched for and deleted all *.exd files, the buttons once again worked for me.
All other users, though, can't start the macro after I save the file.
Simply - if there's a spreadsheet they're using, it works fine.
Once I open and save on exit, the buttons no longer work for anyone else.
They depress, but won't run the macro.
One thing I did notice on the sheet we use the most:
There are 2 buttons, CommandButton1 and CommandButton2.
If another user clicks on button 1 for instance, and I open the code, a new line is created called CommandButton3 (and 4).
I've tried renaming buttons, etc. but this behavior continues and seems to skirt any of my feeble attempts.
Please help and thank you!
Related
I have a workbook in which I consolidate data from various CSV files. There are a number of macros in this file including ones to add new sheets to the file, which is on a shortcut key Ctrl+Shift+N. This has been working perfectly for many years. This morning the shortcut key does absolutely nothing. If I go to the Excel developer tab and click on the Macros button, the list of macros is empty. However, if I open VBA I can run the macro from there and it still works perfectly.
I run Office Professional Plus 2019 and it ran an update yesterday. Does anyone know of a new setting introduced that may hide the macros in Excel itself. Note that macros are enabled on this workbook.
Just for closure should someone else stumble across this. The problem was related to the specific file. It somehow got "partially" corrupted. Still worked and could fire macros from VBA IDE as well as linked buttons, just not with shortcut keys as macros not "visible" in Excel view. File degraded further to a point where it could no longer save.
I have some macros attached to buttons in the Quick Access Ribbon. All but one of the buttons have been functioning normally, so I'm not sure when this started.
I tried to use a less-used macro button this morning called Unhide All Sheets and it threw this error:
Cannot run the macro 'PERSONAL.XLSB!UnhideAllSheets.UnhideAllSheets'. The macro may not be available in this workbook or all macros may be deleted."
So I went to review my code and all my macros are invisible from the front-end. I select Developer -> Macros, the list is completely empty, and when I attempt to create new buttons on the Quick Access Toolbar, the macro list there is also completely empty.
When I hit Alt + F11 to open the VBA editor, I can see and update macros in specific workbooks and in my personal workbook. Most of them still run, although the offending macro (UnhideAllSheets) throws an Unexpected Error (35005) when run from the editor.
Anybody ever seen this before? I've been googling for an hour with no results.
Most Macro Buttons still work
Nothing on the Macro List
Customize Ribbon can't see the macros
Still visible and functioning in VBA Editor (except for "UnhideAllSheets")
I have same issue and I manually checked/marked atpvbaen in the tools>references. This has solved my problem !
I was facing a similar issue, where some buttons were working and some weren't. What I noticed was my module's name was similar to my procedure's (macro's) name. I'm not aware of the reason, but I when ensured procedures names' are different than the module names.
I have a workbook with several command buttons that used to retrieve data, from other sheets, hide and show worksheets and command buttons.
All of a sudden, several, but not all of the buttons wont click. If I step through the code using F8 in the VB window, if the code is to unhide and activate a sheet, the code is taking me to a different sheet.
Is this a known bug? I haven't supplied the code as I know the code works fine
Any help appreciated
Ok, So for some buttons I replaced and this worked, then I noticed in design mode if I just move the buttons to a different location on the same page, exit design mode, then remove back to where I want them to be, all is fine and they work as intended.
Very strange
I am seeing buttons disappear throughout Office programs - does anyone know why this may be happening? The first screenshot below is the VBE window when it first opens - if I drag a toolbar to a new location, all of its icons appear, but as soon as the mouse hovers over a button, the image disappears (though the button can still be clicked).
Other times when I open the VBE window, though, all of the buttons display correctly and do not disappear when the mouse cursor moves over them (not sure why this happens sometimes).
The other place I have noticed buttons disappearing is in the popup dialogs that appear when you copy/paste, for example. The buttons and drop-down choices exhibit the same behavior - some images are gone from the start (i.e. the initial pop-up button) and some disappear when the mouse moves over them (the dropdown choice buttons).
I also have this problem quite frequently. My research turned up things like "print = true in the properties" (which I usually don't want), "take focus on click", etc. etc. The only thing I've found that works 100% for me (whether right, wrong or indifferent) is to do the following with each button.
Private Sub CommandButton10_Click()
'__SEARCH FOR SOMETHING BY NAME__
With Me.CommandButton10
.Left = 860.5
.Top = 47.25
.Width = 50.25
.Height = 25.5
End With
'The rest of your code goes here..
End Sub
I know it's a pain to do it this way, and every time you click a button it
resets itself to the position, but I haven't lost a button since I started doing this. Now I do every button I use like this. I too would accept a "proper" fix if someone could come up with one. Hope this helps a little.
I am using an excel 2003 file but running it in excel 2007. I have an issue where suddenly ALL the macro buttons (about 25) disappeared on one of the tabs in my spreadsheet. Macros in the other tabs are not affected. The macros disappear only from the one tab. After several years of having to restore from a master file and update the data, I tried moving the macros (and changing the size slightly) that were on line 1 of the sheet (there are also macros further down the sheet and in different rows) so that they no longer touched the bottom of line 1 and have not had an issue now for 2 weeks. (The issue was happening every day the file was used). I think I suddenly stumbled upon a cure, but time will tell.
I am using excel 2003 on Windows 7. On my laptop left side USB drive G:/ needs something in the root section or all of my Buttons and checkboxes disappear. This happens to all routines written in the last 10 years.
Excel is installed on the C: drive and all files are run and saved there.
My removable drive letters got switch around and so my buttons disappeared when touched and then all of them. I manually set the drive letter of the USB drive back to G:\ and everything appeared as normal with just a few days of panic. A new USB stick in G: will also cause the problem, so whatever is in the root of the old stick I copy over to the new stick. Have not figured out what excel is looking for on the G: drive that causes the images to not show up. I have been to this forum hoping to find an answer over the years so hope this works for someone else.
Apologies if this is a really stupid question but I've not been able to find a solution.
I've got a main page on my Excel workbook with a number of filter options and some buttons linked to vba code. When clicking the button it takes you another tab with a load of data filtered appropritately. There is a button there that removes the filters and takes you back.
This all works fine but what I want to do is stop people being able to manually change sheets but clicking on the tabs at the bottom of the screen. So far the only method I've found is hiding them, but this obviously doesn't work as you then can't see that data.
You can disable the editing of the sheet tab names by turning them off on the excel options as mentioned in the comment above. The downside to this approach is the user won't be able to see what sheet they are on (which I find incredibly frustrating).
The better method in my mind is to set up an event listener for when the user changes the name of the tab. You can then send a pop up box that appears when the user attempts to change the tab name.