Something to try:
Set the excel macro security to medium or high.
Create a new spreadsheet.
record a simply macro (eg start recording, just enter some date in cells, stop recording)
save it as book1.xls and close excel.
then make a .vbs file with this next bit in it:
Code:
Set AppXcell = CreateObject("Excel.Application")
AppXcell.Visible = True
Set filenm=CreateObject("Scripting.FileSystemObject").Getfile("Book1.xls")
AppXcell.Workbooks.Open (filenm)
now open the book1.xls - youll get a prompt about the macro security. so do whatever and close excel. this is normal.
now open run the vbs. the xls file opens and you can go to macros and run the macro with no security message box!?
why does this happen?
i've tested only in excel 2002 and 2003 (xp sp2). does this happen in the latest excel?
hi everybody
i am using excel 2007 but i cant make any macro.
i have enable macro security to low.(exactly as mrexcel youtube video)
i cant use macro opname or any of my macros
fout message:
the VBA-project, the ActiveX-besturingselementen and other programmeerfunctions from this workmap wil be lost.
can somebody tell me what am i doing wrong?
i cant start any of my macro's in excel 2007
Something to try:
Set the excel macro security to medium or high.
Create a new spreadsheet.
record a simply macro (eg start recording, just enter some date in cells, stop recording)
save it as book1.xls and close excel.
then make a .vbs file with this next bit in it:
Code:
Set AppXcell = CreateObject("Excel.Application")
AppXcell.Visible = True
Set filenm=CreateObject("Scripting.FileSystemObject").Getfile("Book1.xls")
AppXcell.Workbooks.Open (filenm)
now open the book1.xls - youll get a prompt about the macro security. so do whatever and close excel. this is normal.
now open run the vbs. the xls file opens and you can go to macros and run the macro with no security message box!?
why does this happen?
i've tested only in excel 2002 and 2003 (xp sp2). does this happen in the latest excel?
Our IT folks have locked down our macro security settings, requiring a response to the prompt on all files being opened which contain macros.
I have written (in previous versions of Excel) macros that open up multiple files. Is there code that can be written into these macros that will prevent the user from having to manually respond to the prompts each time a file is programmatically opened?
I'm running Excel 2003. I have a file that I'm trying to record a macro against. I have no problem recording the macro, but later, after saving the macro and the file to which it's associated, and then trying to open my file again, I get a message telling me that I can't use my macro because my security is set to high.
That is not the case, however, because I have deliberately set my security to low.
If anyone has an idea or two for getting around this aggravation, I'd love to hear it. Thanks in advance!
Hello,
Is there a way to set it up so the user has to have Macro Security set at Medium in order to continue to use the workbook? I already have a big note on the startup sheet, but I still get calls from users who have their setting at High.
I attempted this, but it doesn't work:
Code:
Private Sub Workbook_Open()
Dim secAutomation As MsoAutomationSecurity
secAutomation = Application.AutomationSecurity
MsgBox "Your macro security is " & secAutomation
If secAutomation = msoAutomationSecurityHigh Then
DisplayAlerts = False
Application.Quit
End If
End Sub
(I tried this with Excel 2007, but the Macro Security settings read differently than with 2003. Is there a macro that works on both versions?)
Thanks for the help!
VR/Lost
Hi All,
This is my first post.
I have a scenario in which through VB.NET, I have to check the Excel Macro security level set in a target machine. In this case, i have an office 2003 installed. So thru UI, i know how to check the Macro security level.
But through VB.net, is there any way to check this. After googling for a while, I found Registry can be used, but couldn't find any registry of that sort..
Is there anything already defined in VB.net that i could use directly to the excel macro level? Or any WMI calls that could get the excel macro level?
Any reply would be appreciated..
Manesh S
I've instilled Excel 2007 on several PCs and written lots of macros in Excel 2007, and never had any problems. Today I installed Excel 2007 on a new PC. I've set macro security to enable all macros, and added the developer tab to the toolbar. However anything to do with VBA - record new macro, visual basic editor etc - is greyed out, as if I hadn't set the security option. I've closed and repoened Excel and the option is still set, but it won't let me create new macros. Have I forgotten another setting somewhere?
Thanks
(Vista Premium, McAfee Internet Security installed - hate the product, doesn't have any obvious way of disabling all functions quickly)
Once I save a file in 97-2002 & 5.0/95 should all users with excel 95 be able to open the file? I have sent out a file and some users are having problems opening it. Can somebody please assist?
Also, will high security levekls prevent users from opening a file with formulas?
Thanks in advance.
Skiman
All,
I have a colleague here in my office who is complaining that his excel is changing the security level for macros from Med to High by itself!
Is he mental - could a macro he wrote do this? virus?
His solution is to change security setting close and reopen excel. this works
any help appreciated
joxer