AppDomain.CurrentDomain.BaseDirectory
就这么一句话
C# windows服务:如何获取服务程序所在的文件夹
原文:http://www.cnblogs.com/lujin49/p/3556756.html