Please help. For some reasons, any Excel file that contains Macro does not work stating that the "The Macro may not be available in this workbook or all macros may be disable". I changed the settings in the trust center but with no luck, still does not run at all.
Many thanks,
This is a little late, but posting for others that may be looking for a solution. Try the solution posted at the link below: browse to the location of the file and open the file under the option "Open and Repair", this repaired the hidden macros for me. enter image description here
https://www.stellarinfo.com/blog/fix-excel-error-unable-to-save-excel-workbook/
Related
i just recieved an e-mail with a virus embeded in xlsm format. So how i'm curious i wanted to check the code. Enabled everything of security on Excel to avoid events starting and other stuffs after opening the contamined file.
Kaspersky flagged the file instantly so i had to disable it.
So i opened the file, and excel showed me a prompt that i had to need disable some security features for the macro run normally. Well, i just ignored it and i went to the vba area to check the code and i found some modules, but every was empty.
Someone can explain me how is it possibile and if there's a way for me check the code?
Thank you.
When you click a link in an Excel workbook, you get a warning 'Some files contain virus ... Would you like to open this file?'
Is there a way to turn this off/include it in a macro or script?
I have a macro that opens the link, but you have to manually click 'Yes' to keep the macro running. I want to run the macro and not have to do any user inputs. I've google'd it and there's a bunch of Registry Edit methods which don't seem to work for me. Any other ways to accomplish this?
There is a good reason for the macro runs to be prevented per default. Power plants have been attacked successfully because someone did run an Excel macro. The world would be a better place if the macros never existed. Look at least over the first 10 minutes.
https://youtu.be/xVBaPZqoLkc?t=910
Security that can be bypassed is no security! Actually that is why you cannot bypass security.
There is no way to bypass this warning. The messeage is there for a good reason.
Otherwise your macro could download a dangerous file and run the code in that file without warning the user.
I automatically open, edit, save and close several Excel workbooks from a Sharepoint location. The following code opens the workbooks (path loops through a list to hit each workbook name):
Workbooks.Open Filename:=path, ReadOnly:=False, Editable:=True
The files open in Read-Only mode, and the yellow dialogue option to Enable Editing does not appear.
I edit these workbooks manually and through a macro, but I am unable to save the files back onto the Sharepoint afterwards without saving as a new file.
I am using Excel 2013. This was working as intended about a year ago, but I believe there may have been updates to Office 365. I checked all of the Excel workbook security options, and nothing is set to open by default as Read-Only.
Is there any way to open the file in an editable mode through the macro, or at the very least allow the Enable Editing option to appear for each workbook?
I have been trying to fix the same problem for my files, and eventually did! So I felt that I could maybe let others know. And this old-ish thread came up near the top of my google search.
What fixed it for me was to edit the link.
from:
https://Company.sharepoint.com/:x:/r/teams/TeamNo/Shared%20Documents/Example/CoolFolder/TheBestExcelFile.xlsm
To:
https://Company.sharepoint.com/teams/TeamNo/Shared%20Documents/Example/CoolFolder/TheBestExcelFile.xlsm
Note that I only used replace to get rid of :x:/r/. I feel like I should have noticed this before but I didn't and no amount of meddling with the Workbook.Open parameters got me anywhere. It just seems odd that the default link copy thing gives you one with special commands in it. For our company most folders have spaces so the link has tons of "%20" in there so I simply read over the ":x:/r/".
Hope it helps someone.
Just for clarity, try this:
Sub Example()
'1.) Get filepath from somewhere
FilePath = Replace("https://Company.sharepoint.com/:x:/r/teams/TeamNo/Shared%20Documents/Example/CoolFolder/TheBestExcelFile.xlsm", ":x:/r/", "")
'2.) Open the file
Set StatisticsFile = Workbooks.Open(FileName:=FilePath, Password:="123")
'3.) Do things
'4.) Close the Sheet, save the changes. I simply like it this way, could be done in a single line.
StatisticsFile.Save
StatisticsFile.Close savechanges:=False
End Sub
I noticed this solution because I could still save the .xlsx file manually with the same name if I navigated to SaveAs. So if you guys can still do that after opening the file via macro, try a similar solution.
The interaction designed for Excel-OneDrive-SharePoint is new in 2016 apps and that version is a requisite to properly work.
The version 2013 may work by tweaking the OnDrive “Account” settings regarding Office co-authoring configuration which is specifically applied to Excel and Word
Right click the OneDrive icon in the taskbar to reach settings
Good luck!
I know your query was posted long ago but I have found the solution to remove the Read-Only blocker and update the excel document via Macro:
If you add "ActiveWorkbook.LockServerFile" after the code of opening the file, then it removes the Read-only and updates the excel as normal.
I have been searching on the internet this error about excel.
"Excel found unreadable content in filename.xls. Do you want to recover the contents of this workbook? If you trust the source of this workbook, click Yes."
When I go to Microsoft Support website, I saw this solution
http://support.microsoft.com/kb/929766/en-us
In this page it says "To resolve this issue, remove the expressions from all Current Time Member and weight on the KPI properties." I did not understand what to do exactly. Please help me
This is an old question but I wanted to say that. There are lots of ways which you can see this error. Firstly, your computer's clock. you should set it to your terratory. Secondly the Excel version. You should use a formal instance of Microsoft Excel. If you do not want to deal with Microsoft, LibreOffice is free and full of good features. You should try that.
Click yes, save under a new filename, and check the contents match what you expect. If you're able to restore using "Restore previous versions" (right click on the file in explorer) then that's an option as well.
I don´t understand why, but it´s the second or third time I've lost my Personal Workbook with all my macro copies. The only different thing that I've done was editing a macro but, when excel was closing, I haven't saved the changes. Next time I've opened excel, surprise, surprise, no Personal Workbook! Has anyone had the same problem? Does anyone know why it happens? I have already searched in (I believe so) all possible folders where It could be stored.
Thanks!
the file can be found for 2007/2010 users in :
C:\Users\User ID\AppData\Roaming\Microsoft\Excel\XLSTART
or somewhere similar for others.
Hope this helps
The folder where the personal macros are saved can be found by using the command:
?Application.StartupPath (without "" sign) in VBA.
Open VBA (ALT+F11) and enter the command in the field on the bottom.
Hope this helped
Using Microsoft office 365. Lost Excel and Word Macros during last update. Had an Excel File that I had copied to my laptop (Windows 10) which had not been updated. Brought it up on my desktop. Was able to see modules but no content. Was unable to remove modules. Uninstalled Office 365. After reinstall, was able to see and use macros from that file. Word macro not retrieved. Hope it helps someone.
Mine went missing completely and was not in the xlstart folder. I finally discovered it was because I'm on a work server, files are all network storage based, and I had just changed my network password. I think the mis-match caused my links to personal files to be temporarily broken. I logged out completely, and back in, and everything was back where it should be.
In short: I tried turning it off and turning it back on again.
For those using MacOS / OSX (El Capitan) with Excel 2016 I located my copy of Personal Macro Workbook.xlsb, which I had previously unhidden in Excel, then closed, in the following location:
~/Library/Containers/com.microsoft.Excel/Data/Application Support/User/Personal Macro Workbook.xlsb
Please note that I used multiple search functions within OSX which did not return this file in the search results for some reason.