Bohn
Bohn

Reputation: 26919

Find DLL name by having name of the Namespace

In the code there is a line like this:

Company.Security.Logs.LogEvent myLog = null;

Now in another project I want to do the same but I don't know which "reference" should I add to my project? So how do I know in which of the references in this project we have this Security class?

Upvotes: 0

Views: 567

Answers (2)

Fernando Espinosa
Fernando Espinosa

Reputation: 4825

You can use Visual Studio "Go to Definition" (or F12) when the caret is over the name of the type, in this case, LogEvent. it will take you to a condensed API source file in the text editor that will have the first lines looking something like:

#region Assembly System.Windows.Forms.dll, v4.0.0.0
// C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\System.Windows.Forms.dll
#endregion

Upvotes: 2

Joe Enos
Joe Enos

Reputation: 40393

Right click on the class name in Visual Studio and Go to Declaration. This will take you either to a DLL view or code view, either of which will tell you which assembly the class lives in.

Upvotes: 2

Related Questions