获取项目中其他文件

获取 bin 同级文件夹 assets 中的 test.html

AppDomain.CurrentDomain.BaseDirectory + @"../../assets/test.html"

其中 AppDomain.CurrentDomain.BaseDirectory 的值为

C:\Users\kylew\Desktop\WindowsFormsApp1\WindowsFormsApp1\bin\Debug\
posted @ 2018-11-22 15:49  Kyle0418  阅读(170)  评论(0编辑  收藏  举报