Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 989
Default Excel 2003 - Error Running Macro

I have received some responses to this error recently, but am interested in
others' ideas.

A program that runs in Excel 2002 will not in Excel 2003. The Excel 2003 is
on an entirely different machine.

It gets hung-up on the "For Each" line in the following code:

Dim vbModule As Object
For Each vbModule In appWB.ActiveWorkbook.VBProject.VBComponents
If vbModule.Type = 1 Then ' "1" is a module
appWB.ActiveWorkbook.VBProject.VBComponents.Remove vbModule
End If
Next vbModule

The error reads: "Run Time Error '1004' Programmatic access to Visual Basic
Project is not trusted".

We have checked the "Trust Access to Visual Basic Project" check box in the
ToolsMacroSecurityTrusted Sources tab (at the bottom)

Any ideas?

Thank you, Mark
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
I tried to get around the problem of the pivot table field settingdefaulting to Count instead of Sum by running a macro of change the settingfrom Count to Sum. However, when I tried to run the Macro, I got error messageof run time error 1004, unable Enda80 Excel Worksheet Functions 1 May 3rd 08 02:35 PM
I tried to get around the problem of the pivot table field settingdefaulting to Count instead of Sum by running a macro of change the settingfrom Count to Sum. However, when I tried to run the Macro, I got error messageof run time error 1004, unable Enda80 Excel Discussion (Misc queries) 1 May 3rd 08 10:52 AM
Excel 2003 - Error Running Macro Mark Excel Programming 2 June 17th 05 06:00 PM
Error when running macro in Excel Raphael Saddy Excel Programming 4 April 12th 04 09:09 PM
KERNEL32.DLL error after running EXCEL Macro Dan[_16_] Excel Programming 0 July 23rd 03 08:15 PM


All times are GMT +1. The time now is 01:41 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"