[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 369
  • Last Modified:

vs2005 wont run any macros

my vs2005 refuses to run any macros.
It does record macros but when I try to run them nothing happens.

this is even for the simplest macros such as :
Public Module RecordingModule
    Sub TemporaryMacro()
        DTE.ActiveDocument.Selection.Text = "aaa"
    End Sub
End Module

Tools- > Options -> Environment-Add-in/Macros Security first two checkboxes are checked.
0
SnowFlake
Asked:
SnowFlake
  • 5
  • 4
1 Solution
 
jpaulinoCommented:
If you already restart your VS2005, then open then open your Macro IDE and check if you dont have any error in the error list.  
0
 
SnowFlakeAuthor Commented:
I did (restart) and no, there is no error in the error list.
0
 
jpaulinoCommented:
>> there is no error in the error list.

You have build it in the IDE Macro Editor to ensure that ?

You can also in the IDE Macro Editor select Debug -> Enable debuggin and then add some breackpoints to your macro.
0
Get your Conversational Ransomware Defense e‑book

This e-book gives you an insight into the ransomware threat and reviews the fundamentals of top-notch ransomware preparedness and recovery. To help you protect yourself and your organization. The initial infection may be inevitable, so the best protection is to be fully prepared.

 
SnowFlakeAuthor Commented:
when I press build inside the IDE macro editor nothing happens
and if I try to set debug and add a breakpoint the breakpoint symbol is hollow and it says that "The breakpoint will not currently be hit. no symbols have been loaded for this document".
:(
0
 
SnowFlakeAuthor Commented:
I also noticed that when I select "Enable debugging" I get the following on my output window:

'vsmsvr.exe' (Managed): Loaded 'C:\WINDOWS\assembly\GAC_32\mscorlib\2.0.0.0__b77a5c561934e089\mscorlib.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.
The program '[4908] vsmsvr.exe: Managed' has exited with code 0 (0x0).

(where is this 'Just My Code'  setting and what does it mean ?
0
 
jpaulinoCommented:
That message appears to me to.

Have you check the references. Do you have EnvDTE, EnvDTE80, VSLangProj and VsMacroHierarchyLib ?
0
 
SnowFlakeAuthor Commented:
I have all of them on my Mymacros solution AND
Microsoft.VisualStudio.CommandBars
Microsoft.Vsa
System
System.Windows.Forms

(and the samples solution also has System.Drawing)
maybe I should remove some of them ?
0
 
jpaulinoCommented:
No don't do that. I have also all those, but the other ones that I've send you are the main.

If you really need to use macro I will suggest you to reinstall VS and add all components. With me it works fine, maybe you have some damage dll or configuration that I can not see it.
0
 
SnowFlakeAuthor Commented:
I have graded answer Q with a  B grade,
because although it would probably work it is too drastic for me to implement,
so basicly I was left will the problem.
but still I prefer grading myself.
if it was possible I would have given a higher grade for the help effort and a lower one for the effort's results.

thanks jpaulino
0

Featured Post

Upgrade your Question Security!

Add Premium security features to your question to ensure its privacy or anonymity. Learn more about your ability to control Question Security today.

  • 5
  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now