Hey Guys,
I'm working on a webapplication and I'm saving files .pdf in a folder called "Files" inside of the application project...
So, I display these pdf files but I got a nasty problem, with delete them, It's driving me nuts....
because I every time I try to do it, I get this exception:
"File does not exist", It couldn't be found... BUT the goddamned File does exist..
In fact, I display this pdf file (with response.transmitfile) with the same string path and It works... but when I try to delete it with the methos from IO.. It doesn't work at all..
Here' part my code:
string path = @"Files" + "\" +filename.pdf;
if (File.Exists(path))
{
File.Delete(path);
elimino = true;
}
So, anybody knows how can I solve this problem???
Thanks...