Where should I reference Microsoft.ManagementConsole.dll from?
-
27-05-2021 - |
Question
I'm trying to follow the instructions located at How-To Create a Hello World Snap-in using Visual Studio 2010 and it tells me I need to reference Micorosft.MagamentConsole.dll which can be found in the MMC 3.0 SDK, which is in turn part of the Windows SDK.
My problem is that I already have the Windows SDK installed (specifically the Microsoft Windows SDK for Windows 7, both versions 7.0 and 7.1 (I'm not sure what the difference is)) however I cant find the required Microsoft.ManagementConsole.dll assembly anywhere:
- Its not listed in the .Net tab of the Add reference... dialog in Visual Studio (even if I change the project target framework to .Net v2.0)
- Its not in any of the Microsoft SDKs\Windows folders in either the Program Files or Program Files (x86) directories
- Its also not in the Visual Studio 2010 installation directory
- And its also not in c:\Windows\System32 (as one guide I found on the internet suggested that it might be)
Where can I / should I reference this assembly from?
Solution
On my system it is located in %ProgramFiles%\Reference Assemblies\Microsoft\MMC\v3.0
. That location, "reference assemblies", also suggests it is the place you should include it from.
OTHER TIPS
This worked for me
project -> Add Reference -> Browse -> paste this value C:\Windows\assembly\GAC_MSIL\microsoft.managementconsole\3.0.0.0__31bf3856ad364e35\microsoft.managementconsole.dll
Notes:
- You can not browse to the above location using windows explorer
- However you can go to the above path in command line