How to map network drive in C#?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

hihi
when I am using Platform SDK, I can use WNetAddConnection2 to connect the network drive. But i cannot found these similar function or method in C#. Anyone know C# has this class to do it?

thx...
 
use P/Invoke

--
Vladimir Scherbina
Ukraine, Kiev.
--

teddy said:
hihi,
when I am using Platform SDK, I can use WNetAddConnection2 to connect the
network drive. But i cannot found these similar function or method in C#.
Anyone know C# has this class to do it??
 
Don't map network drives, use UNC paths in your C# code, mapping network
drives belongs to the DOS world.

Willy.
 
use P/Invoke

Go find the C# statement to use this method using P/Invoke on this
great site:

www.pinvoke.net

Just search for your Win32 API function you're interested in, and
you'll get your answers!

Marc
================================================================
Marc Scheuner May The Source Be With You!
Bern, Switzerland m.scheuner(at)inova.ch
 
Back
Top