beaker,
Task manager's Application tab shows the caption of the application's
top-level windows.
The process tab on the other hand shows the name of the executables. As long
as there are couple of ways you can get that I think the easises is to
extract the file name from
Application.ExecutablePath. To extract the file name only you can use the
Path.GetFileName.
I don't know about Application.ProductName. I personally have never used it,
but if you say that this is not what you want then try using
Application.ExecutablePath.
If you want to get reference to the executable file assembly you can use
Assembly.GetEntryAssembly static method.
--
HTH
Stoitcho Goutsev (100)
"beaker" <ra*********@notrealcompanyIhope.com> wrote in message
news:u4****************@TK2MSFTNGP14.phx.gbl...
Larry Lard wrote: beaker wrote:
Hello,
Is there a way to get the name of my application (as it appears on the
list of processes running) at runtime?
Application.ProductName
Thanks for the reply, but I believe that only gives me the assembly name
(as filled in in my AssemblyInfo.cs), and not the name of the .exe - which
aren't neccessarily the same (I tried renaming my app to check).
Gary