How to get path to DLL within a class library

D

Don

Is it possible to determine where the DLL itself exists from within a class
library project at runtime, similar to the way Application.StartupPath works
for a windows application project?

- Don
 
H

Herfried K. Wagner [MVP]

* "Don said:
Is it possible to determine where the DLL itself exists from within a class
library project at runtime, similar to the way Application.StartupPath works
for a windows application project?

\\\
MsgBox(System.Reflection.Assembly.GetAssembly(Me.GetType()).Location)
///
 
M

Mattias Sjögren

Is it possible to determine where the DLL itself exists from within a class
library project at runtime, similar to the way Application.StartupPath works
for a windows application project?


GetType(SomeClassOfYours).Assembly.Location



Mattias
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top