Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I can map a network share point to a local logical drive by using net.exe like this:

net use J: \\cnf001\test\folder1 /user: ...

I build a C# lib to use Process to simulate the mapping. Now I have a case I need to map: a share point in "My Computer"->"My Network Places"->[share node], where "share node" is in the format https://...

I cannot use net.exe any more, or I am not sure what parameters I can use if possible? Anyway, is it possible to build map drive for this case? How? Do I need some other tools

share|improve this question

migrated from stackoverflow.com Jul 20 '09 at 20:12

This question came from our site for professional and enthusiast programmers.

    
My client has a https://.. share point available with user name and pwd. What I need to do is to put a text file there in a folder. I guess I need to build a map drive first, then use System.IO to output file there. –  David Chu Jul 20 '09 at 16:31
    
I guess I cannot use net.exe but I can use ftp to transfer the file. Any information about its parameters to send file to a host so that I can invoke the process in C#? –  David Chu Jul 20 '09 at 16:45
add comment

3 Answers

You can do this if the server at the HTTP(s) supports WebDAV. WebDAV is available on most web platforms so it shouldn't be an issue to enable it.

http://en.wikipedia.org/wiki/WebDAV

share|improve this answer
    
The question is about the client, not the server. –  doekman Aug 27 '09 at 13:52
    
This is an answer about the client as well. WebDAV is a widely supported protocol for just this type of stuff; mounting and accessing a file system via HTTP. –  Nissan Fan Oct 6 '09 at 17:29
add comment

You can check the following article: Reading contents of Web Folders in C#. In a nutshell, the folders in My Network Places are just file system shortcuts located in Documents and Settings\$USER$\NetHood (XP) / Users\$USER$\AppData\Roaming\Microsoft\Windows\Network Shortcuts (Vista).

And regarding your comment on using FTP - you can use System.Net.FtpWebRequest class or System.Net.WebClient class.

share|improve this answer
add comment

On windows, you need a third party tool. For example DriveOnWeb. I used an OEM version, which only works with my ISP, but it works great.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.