${res:Templates.Project.WindowsService.Name}
C#
${res:Templates.File.Categories.WindowsApplications}
C#.Project.ServiceProject
${res:Templates.Project.WindowsService.Description}
v2.0
Exe
Properties
/// Clean up any resources being used.
///
protected override void Dispose(bool disposing)
{
// TODO: Add cleanup code here (if required)
base.Dispose(disposing);
}
///
/// Start this service.
///
protected override void OnStart(string[] args)
{
// TODO: Add start code here (if required) to start your service.
}
///
/// Stop this service.
///
protected override void OnStop()
{
// TODO: Add tear-down code here (if required) to stop your service.
}
}
}
]]>
/// This method starts the service.
///
static void Main()
{
// To run more than one service you have to add them here
ServiceBase.Run(new ServiceBase[] { new ${ProjectName}() });
}
}
}
]]>