Re: Get file path from the client
"Sathyaish" <sathyaish@gmail.com> wrote in message
news:1165920518.066339.306840@73g2000cwn.googlegroups.com...
public void btnOK_Click(object sender, EventArgs e)
{
//psuedocode
string sPath = FileDialog.Show();
//sPath is the location and name of the file on the client's hard
drive
}
Just to pick a nit, I wrote the wrong psuedocode for ASP.NET, I
realize. The filedialog returns a DialogResult and not a filename. The
file name can be known from the filedialog's FileName property, so it'd
look more like:
public void btnOK_Click(object sender, EventArgs e)
{
//psuedocode
FileDialog.Show();
string sPath = FileDialog.FileName();
//sPath is the location and name of the file on the client's hard
drive
}
or something like that. So, it is possible in ASP.NET. Is it possible
in Java/JSP/whatever?
I am shocked that this is possible via ASP.NET. Can you post a link to
an ASP.NET page which just gives me a file save dialog, and then I'll try
saving it somewhere, and then your page tells me the filename of the file I
saved it to? I can't bring myself to believe that ASP.NET would provide such
a privacy breach. I'm expecting for the code on the serverside to throw some
sort of security exception or something like that. I really have to see this
for myself.
- Oliver