LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
tom tom is offline
external usenet poster
 
Posts: 570
Default Macro Still Won't Run in Excel 2003

I work with Mark who posted the following last week:

We get the error: "Run Time Error '1004' Programmatic access to Visual Basic
Project is not trusted". 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

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

Any Ideas?

A poster in this newsgroup suggested that we check the registry, but not
sure how to do this. Instruction in this area would be appreciated.

Thank you, Mark"

After making sure we checked the appropriate resource under the tools menu
in the VBA editor, the macro did in fact run on my desk top computer.
However, checking this box on my lap top computer does not resolve the
problem. I have verified that both machines have the same resources checked
off, same product ID, version, and service pack. Any thoughts on why this
would work in some cases but not others?

Tom
 
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
how to run acces 2003 macro in excell 2003 macro gonggo Excel Discussion (Misc queries) 0 October 6th 09 11:45 AM
Excel 2003 VBA Macro Partly Void[_2_] Excel Discussion (Misc queries) 1 July 6th 09 01:32 PM
Macro - Help Please Excel 2003 Paul Excel Discussion (Misc queries) 6 June 23rd 09 03:19 AM
Macro - Excel 2003 Dan Excel Discussion (Misc queries) 3 September 16th 08 08:28 PM
macro in excel 2003 constance Excel Worksheet Functions 1 March 21st 05 09:50 AM


All times are GMT +1. The time now is 09:41 AM.

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"