Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

List files in unc path

Status
Not open for further replies.

Trebor100

Programmer
Mar 14, 2006
90
GB
Hi all,

Quick question. I have a unc path which contains a load of files. i need a routine that can list all the files in this folder. anyone got any ideas?

thanks in advance
Rob
 
Is this a path on the web server or a network share?
You will probably need to go with server-side code for something like this.

What is the purpose for listing these files? Is it for a web application or something you are running locally on your own machine to list files elsewhere?


At my age I still learn something new every day, but I forget two others.
 
its going to run on a webpage on the intranet. the unc path in question is a network share which all users will have access to. the file listing is going to be a load of printers from which users can then click to install.
 
I wish you luck but I do not think this is going to work.

First, you should have server-side code to list the files in the network share. You may or may not run into some permissions issues. I have done this with ASP code in the past.
To do it through javascript you have to go through the client's computer which means ActiveX controls, security warnings and of course a limitation to Internet Explorer only due to use of ActiveX.

The big problem is not listing out the printers but triggering the installation. Clicking on a link to a printer from IE does not trigger the printer install the same way it would when browsing to it through Windows Explorer. Someone else was attempting this in the ASP forum a while back and had no success.

At my age I still learn something new every day, but I forget two others.
 
cheers for the views theniteowl. i'll look into doing it server side via asp.net and c#.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top