Automation Error Exception Occurred Project 2010
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Automation Error. Exception Occurred when running a macro up vote 0 down vote favorite I've recently been having issues running macros on one computer running Excel 2010 on Windows 7 Professional. Whenever I try to run a macro, I get an indefinite progress bar with a message 'Please wait...' and the workbook grays out slightly in the background. After a period of time, I get the error Automation Error. Exception occurred and the workbook closes. For all intents and purposes, the specific macro doesn't seem to matter, as I've written basic MsgBox Hello World scripts and they throw the same error. What's unique is that I do not get this error if I either (1) run the macro from within the VBE, or (2) have the VBE open in the background. It seems that having the VBE open allows me to run macros. I've done some searching and haven't found any solutions that matched my situation. I'd appreciate any help. excel vba excel-vba excel-2010 share|improve this question asked Apr 21 at 20:13 user3561813 3,3041417 2 This was asked a day or two ago... let me see if I can find it. Edit: see here. –findwindow Apr 21 at 20:15 @findwindow Thanks for the link. While it sounds like some of the symptoms may be the same, I'm not sure that it's the same problem. I'm not calling any userforms, and the error occurs even on the simplest lines of code. Again, thanks for the help. I'll continue researching as well to see if I can't figure it all out. –user3561813 Apr 21 at 20:29 Do you have any personal macros that could be firing? –findwindow Apr 21 at 20:32 @findwindow I don't have any personal macros –user3561813 Apr 21 at 20:48 add a comment| active oldest votes Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook. Your
when creating SaveAs file dialog If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. Results 1 to 5 of 5 Thread: [RESOLVED] [Excel 2010] Automation Error when creating SaveAs file dialog Tweet Thread Tools Show Printable Version Subscribe to this Thread… http://stackoverflow.com/questions/36779550/automation-error-exception-occurred-when-running-a-macro Display Linear Mode Switch to Hybrid Mode Switch to Threaded Mode Apr 20th, 2011,01:18 PM #1 UberChemist View Profile View Forum Posts Thread Starter New Member Join Date Apr 2011 Posts 8 [RESOLVED] [Excel 2010] Automation Error when creating SaveAs file dialog I have many macros in my personal workbook (PERSONAL.XLSB), and so when I close all open http://www.vbforums.com/showthread.php?647755-RESOLVED-Excel-2010-Automation-Error-when-creating-SaveAs-file-dialog workbooks the Excel application window stays open and I can still use the Visual Basic editor to edit these macros. I have narrowed my problem down to this: Code: Sub Tester() Dim MyDialog As FileDialog Set MyDialog = Application.FileDialog(msoFileDialogSaveAs) End Sub When I execute this code with a workbook open (like the default Book1), this works fine. If I close all workbooks and execute this code, then I get the following error: Automation error Exception occurred. Then the windows error reporting system chimes in with "Microsoft Excel has encountered a problem and needs to close." and the application closes. I can post the details of the error report if it would help, but otherwise I'll spare you. The error does not occur with the other three types of file dialog (FilePicker, FolderPicker, Open). I want to use this as part of a larger macro that will create a new workbook with certain parameters that I specify, and I need the SaveAs dialog to be able to create a new file. I'd like it
are missing Microsoft Office for Developers > General Office Development Question 0 Sign in to https://social.msdn.microsoft.com/Forums/vstudio/en-US/e9ecd0be-73b9-407f-a608-45a76d9eeafc/ms-project-2010-adding-custom-ui-using-vba-callback-parameters-are-missing?forum=officegeneral vote Hello, I've been trying to add a new tab to http://www.office-forums.com/threads/automation-error-exception-occurred.2021367/ the ribbon in Microsoft Project 2010 by constructing a ribbonXML string and calling ActiveProject.SetCustomUI(ribbonXML) on Project_Open. Here's what my XML string looks like:
Reinhardt Guest I consistently get this error when I get to this line in code. The workbook is saved as an .xls and I'm opening another workbook, converting it to a new format and saving the new workbook. oWB.SaveAs Filename:="test.xls", FileFormat:=56 The current fileformat of oWB is 56 and the file name is MyFileName.xls After Excel crashes I get the following error (sometimes) Microsoft Office Excel has encountered a problem and needs to close. ... Dueing the recovery, I get this message Automation error. Exception Occurred and I enter OK. I've actually put in On Error Resume next to see if I can capture the Err code, but it crashes before I get the code. When I try to open the Repaired version of the workbook I was trying to save, I get MyOriginalFilename.xls (version 1).xls: file format is not valid. OK, I'm pretty sure I'm using the correct file format, but it's not working. FWIW, I'm using a new laptop and haven't tried to run this code on this machine. I was on 2003 before the refresh and now am on 2007. I haven't tried to run this code in 2007 since I converted to 2007 a couple of weeks back, but I'm not sure if it's the patches or the code. I've had several security updates installed today. They include KB960803, KB959426, KB963027, KB923561, KB956572, KB952004, KB961373. I have no idea if they are related or not. When I run it in Excel 2003, (with this convention) oWB.saveas "myfile.xls" it works fine. What concerns me it that there is another application out there that uses the same SaveAs coding in Excel 2007 that once worked (although when I test that today, it's working fine) When I look at the folder I'm saving to, I see that the Attribute for ReadOnly is greyed out (no X, but not clear). Is there some way I candetermine if I can write to this folder? I did try to use similar saveas cod