I have the following problem:
I want to open an Excel file when I press a button; the file is in a shared folder on a server.
When I'm programming in my localhost
, if it works with this code:
protected void BtnChk_Click(object sender, EventArgs e)
{
Process.Start(@"\server\vol1\Files\Book1.xls");
}
That way I click and look for the route, and the excel file starts automatically.
However, when the web application uploads it to the server assigned host and everything, it does not bring me anything.
How can I make it work, or what else could it do? This code is to verify if the file exists, and if it works for me !! I do not understand why visualize it not
if (File.Exists(@"\server\Files\Book1.xls"))
{
ButCrear.Visible = false;
BtnChk.Visible = true;'
}