// 运行时的dll所在的文件夹地址,比如:D:\Work
Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);
// 运行时的dll的完整地址,比如:D:\Work\RevitDemo.dll
Assembly.GetExecutingAssembly().Location;
// 运行时的dll的名称,比如:RevitDemo.dll
Assembly.GetExecutingAssembly().GetName().Name;
// 当前运行程序域的所在目录(比如在revit插件中,该属性值为:C:\Program Files\Autodesk\Revit 2020)
AppDomain.CurrentDomain.BaseDirectory;
dll路径问题
于 2021-01-03 15:40:57 首次发布