In my code I want to thanks to the good path, open the file Index.html in my IIS server.
我实际上正在使用:
string path = "C://inetpub//wwwroot//Files//Wireframes//" + ((LinkButton)sender).ID;
System.IO.DirectoryInfo di = new System.IO.DirectoryInfo(path);
System.IO.FileInfo[] fiArr = di.GetFiles("*", SearchOption.TopDirectoryOnly);
foreach (System.IO.FileInfo thefile in fiArr)
{
if (thefile.Name == "index.html")
{
System.Diagnostics.Process.Start(path + "/index.html");
}
}
}
我很想知道,为什么它在当地工作,但当我把我的项目放在我的服务器上时,这并不是什么。