By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,805 Members | 1,056 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,805 IT Pros & Developers. It's quick & easy.

Browse Local Drives from Webpage

P: n/a
Hey all,
need sample/article how to let user browse local drives to select a file
and have the local drive location returned so I can store it in my db,
similar to a file upload but without the actual file transfer and I need the
full path...
any assist is greatly appreciated!!
MTIA
wardeaux
Nov 18 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
You could just use a FileUpload control, but don't actually upload the file.
It should give you the full local path.

"Wardeaux" wrote:
Hey all,
need sample/article how to let user browse local drives to select a file
and have the local drive location returned so I can store it in my db,
similar to a file upload but without the actual file transfer and I need the
full path...
any assist is greatly appreciated!!
MTIA
wardeaux

Nov 18 '05 #2

P: n/a
any suggestions on a good one?

"Haacked" <Ha*****@discussions.microsoft.com> wrote in message
news:93**********************************@microsof t.com...
You could just use a FileUpload control, but don't actually upload the file. It should give you the full local path.

"Wardeaux" wrote:
Hey all,
need sample/article how to let user browse local drives to select a file and have the local drive location returned so I can store it in my db,
similar to a file upload but without the actual file transfer and I need the full path...
any assist is greatly appreciated!!
MTIA
wardeaux

Nov 18 '05 #3

P: n/a
You can use a HTML file input control.

<input id="inputfile" style="DISPLAY: none" type="file" name="browser"
runat="server">

Set it up to run at server.

Declare the control as part of page class.

protected System.Web.UI.HtmlControls.HtmlInputFile inputfile;

Then you can use the System.IO namespace to access the file system and the
Browser object to get the filename.

example: string extension =
System.IO.Path.GetExtension(Browser.PostedFile.Fil eName);

Enrique.

"Wardeaux" <wa******@bellsouth.net> wrote in message
news:ud**************@TK2MSFTNGP10.phx.gbl...
Hey all,
need sample/article how to let user browse local drives to select a file
and have the local drive location returned so I can store it in my db,
similar to a file upload but without the actual file transfer and I need
the
full path...
any assist is greatly appreciated!!
MTIA
wardeaux

Nov 18 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.