File Dialog to choose a path and file

  • Thread starter Thread starter B Garrett
  • Start date Start date
B

B Garrett

Hi,


I have a .ASPX page using C# and I need to read in a text file from a
selected path. so in need the file dialog box to allow the user to choose
the path and file that they want to read in.

What command can I use todo this in a .ASPX page, I tried getting it to use
windows that has the file dialog box but cannot get system.window class to
be included in the project.

Thanks,
B Garrett
 
What command can I use todo this in a .ASPX page, I tried getting it to
use windows that has the file dialog box but cannot get system.window
class to be included in the project.

You don't want to mix up Windows Forms and ASP.;Net web pages; they are
entirely different animules. Windows Forms operate in a nice little
persistent sandbox on a local machine. ASP.Net WebForms are HTML pages on
the client, and .Net assemblies on the server. IOW, you are limited on the
client to what is available in an HTML document.

Now, your requirments are fuzzy as you've stated them, although I'm sure
they're clear as a bell to you. But different people will understand the
phrase "read in a text file from a selected path" in different ways. So, how
about telling us in more common geek terms, or more descriptive language
what you're trying to do? For example, do you want to make text files on the
server available for reading to the client users? If not, what exactly do
you want?

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Ambiguity has a certain quality to it.
 
if the file is client side, then use <input type=file>, if server side,
write a directory browser page.

-- bruce (sqlwork.com)
 
Back
Top