wpf 后退父目录
string rootPath = "";
string BaseDirectoryPath = AppDomain.CurrentDomain.BaseDirectory;
rootPath = BaseDirectoryPath.Substring(0, BaseDirectoryPath.LastIndexOf("\\"));
rootPath = rootPath.Substring(0, rootPath.LastIndexOf("\\"));
rootPath = rootPath.Substring(0, rootPath.LastIndexOf("\\"));
string path = rootPath + @"..\Resource\Echarts\echart.html";
or this method
string url = AppDomain.CurrentDomain.BaseDirectory + @"..\..\Resource\Echarts\echart.html";
Web.Navigate(url);

浙公网安备 33010602011771号