473,387 Members | 1,745 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

How to set process name/description?

mdb
When I view my running processes with SysInternals Process Explorer, most of
the processes have actual names (called "Description" in Process Explorer)
and Company Names set for the process. Mine (a .NET windows service) does
not. Anyone know how I can set this value?

--
-mdb
Nov 17 '05 #1
4 13560
Have you created an installer class in the service? Something like
this:

/// <summary>
/// Summary description for ServiceRegister.
/// </summary>
[RunInstaller(true)]
public class ServiceRegister : System.Configuration.Install.Installer
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.Container components = null;
private ServiceInstaller serviceInstaller;
private ServiceProcessInstaller processInstaller;

public ServiceRegister()
{
// This call is required by the Designer.
InitializeComponent();

// define and create the service installer
serviceInstaller = new ServiceInstaller();
serviceInstaller.StartType = ServiceStartMode.Manual;
serviceInstaller.ServiceName = ServiceControl.ServiceControlName;
serviceInstaller.DisplayName = ServiceControl.ServiceControlDesc;
Installers.Add(serviceInstaller);

// define and create the process installer
processInstaller = new ServiceProcessInstaller();
#if RUNUNDERSYSTEM
processInstaller.Account = ServiceAccount.LocalSystem;
#else
//use the local system account
processInstaller.Account = ServiceAccount.LocalSystem;

// should prompt for user on install
//processInstaller.Account = ServiceAccount.User;
//processInstaller.Username = null;
//processInstaller.Password = null;
#endif
Installers.Add(processInstaller);
}

#region Component Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
components = new System.ComponentModel.Container();
}
#endregion
}

Nov 17 '05 #2
mdb
"steve" <st*******@hotmail.com> wrote in
news:11**********************@o13g2000cwo.googlegr oups.com:
Have you created an installer class in the service? Something like
this:
serviceInstaller.ServiceName =
ServiceControl.ServiceControlName;
serviceInstaller.DisplayName =
ServiceControl.ServiceControlDesc;


Yes. Those are used in the Services Control Panel and stored in the
Registry, but apparently are not used for the names of processes that are
actually running. I'm referring to the 'Description' and 'Company Name'
fields found in SysInternals Process Explorer (these bits of information are
apparently NOT available in standard Task Manager.) You can get Process
Explorer at http://www.sysinternals.com/Utilitie...sExplorer.html

--
-mdb
Nov 17 '05 #3
mdb
mdb <m_b_r_a_y@c_t_i_u_s_a__d0t__com> wrote in
news:Xn****************************@207.46.248.16:
When I view my running processes with SysInternals Process Explorer,
most of the processes have actual names (called "Description" in Process
Explorer) and Company Names set for the process. Mine (a .NET windows
service) does not. Anyone know how I can set this value?


Hmmm after a bit of checking, I think that these two properties are built
into the .EXE file itself. (Right-click EXE, Properties...) Then under the
Version tab, there are several properties listed. Both 'Product Name' and
'Company' are blank. I would like to provide values for these, but I have no
idea if VS.NET build can do that... Anyone?

--
-mdb
Nov 17 '05 #4
mdb
mdb <m_b_r_a_y@c_t_i_u_s_a__d0t__com> wrote in
news:Xn****************************@207.46.248.16:
Hmmm after a bit of checking, I think that these two properties are
built into the .EXE file itself. (Right-click EXE, Properties...) Then
under the Version tab, there are several properties listed. Both
'Product Name' and 'Company' are blank. I would like to provide values
for these, but I have no idea if VS.NET build can do that... Anyone?


OK I feel stupid. Its in the AssemblyInfo. 8-|

--
-mdb
Nov 17 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: TJ | last post by:
Making a good old fashioned asp page and need to be able to display the IIS COM+ process id's (i.e. those that show up when attaching to a process in InterDev (in the debug/processes dialog box))....
0
by: microsoft | last post by:
Hi People, when I try to modify an active directory user programatically, I receive the following exception: The server is unwilling to process the request Reading the microsoft web site, I...
1
by: Mullin Yu | last post by:
But, I want is that I can have a Main app that will start a new process or kill one particular or all process. The process will open a console exe. But, I don't want the user to close the console...
2
by: sidd | last post by:
hiAll, is there a way in .net/c# to check if a file is in use with another process. so i am trying to do a File.Move(source,destination)..and if the file is in use, this would through an...
1
by: BenS | last post by:
Good Morning and Happy Wednesday! I've got a web service that exposes a method that takes an string input parameter that specifies an executable on the server that starts a process. These...
11
by: Nurit N | last post by:
This is the third newsgroup that I'm posting my problem. I'm sorry for the multiple posts but the matter becoming urgent. I hope this is the right place for it... I have created a very...
4
by: =?Utf-8?B?UmljaA==?= | last post by:
On a form - I have a datagridview which is docked to the entire form. The datagridview allows users to Delete and/or Add Rows. On the Form_Load event I Fill the datagridview source table with a...
4
by: Brian Gideon | last post by:
I'm having a problem with the amount of time it takes to initialize an application pool on IIS 6.0. Upon the first request to an ASP.NET page the worker process (w3wp.exe) starts up. The problem...
8
by: g3rmanpride21 | last post by:
I'm currently working with this piece of code: CheckedListBox1.Items.Clear() CheckedListBox1.DisplayMember = "ProcessName" Dim p As Process For Each p In Process.GetProcesses...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.