Mapping Network Share Help 
Author Message
 Mapping Network Share Help

Hi
        I'm a beginner with VB.  I'm trying to learn how to map a
network share for a process and then have it remove the share when the
process is done.  Can someone point me to a tutorial or help me out
here?  Thanks
Scott


Wed, 18 Jun 1902 08:00:00 GMT  
 Mapping Network Share Help

Quote:

> Hi
>         I'm a beginner with VB.  I'm trying to learn how to map a
> network share for a process and then have it remove the share when the
> process is done.  Can someone point me to a tutorial or help me out
> here?  Thanks
> Scott

Private Declare Function WNetAddConnection Lib "mpr.dll" _
  Alias "WNetAddConnectionA" _
    (ByVal lpszNetPath As String, ByVal lpszPassword As String, _
     ByVal lpszLocalName As String) As Long

Private Declare Function WNetCancelConnection Lib "mpr.dll" _
  Alias "WNetCancelConnectionA" _
    (ByVal lpszName As String, _
     ByVal bForce As Long) As Long

just add these two declarations to your code, and call them as desired!



Wed, 18 Jun 1902 08:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Map/UnMap Network Share Connections --> VB.Net

2. Map a shared network drive in VB 4.0?

3. Map many network shares using text file

4. Create/Remove drive map to network share

5. how to map a logical drive to a network share from VB

6. Map a network share from VB

7. Map shared network directory through TCP/IP

8. Connecting to network shares when network is detected only - help please

9. get drive size from network network mapped drives

10. Help Mapping network drive !

11. Help - restoring mapped network drives

12. HELP: How to disconnect from a network share???

 

 
Powered by phpBB® Forum Software