我在页面上放了一个按钮来执行一个快捷方式
代码:
 protected void Button1_Click(object sender, EventArgs e)
        {
            object fileName = Request.PhysicalApplicationPath + @"test";
            string path = HttpContext.Current.Server.MapPath("test");            //ShellExecute(IntPtr.Zero, "open", path + ".lnk", null, null, 1);
            string URL = AppConfig.PicturePath;
            Process process = new Process();
            process.StartInfo.FileName = path + @".lnk";
            //文件名必须加后缀。
            process.Start();        }
我直接在VS上运行没问题,但是放到IIS里死活运行不出来,但是代码都走了,上面注掉的那个ShellExecute一样在VS里没问题但是在IIS里就是不行。在线等。
高手指点谢谢。