473,396 Members | 2,034 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

The best way to Connect and Disconnect network drives in VB.Net

Hi

I was wondering if someone can please enlighten me as to the best and most
approved way to connect and disconnect network drives in vb.net.

I have been using Mpr.dll API calls such as WNetCancelConnection2 and
WNetAddConnection2, but these seem to be very flakey with drive
disconnection (The drive conenction seems to be pretty good).

I would have through that Microsocft would have provided a simple class you
can call to take care of mapping network drives etc, but so far i have only
found API calls as the way to do this.

Has any one got a rock solid stable way to connect and disconnect network
drives in vb.net?

many thanks

Sparky.
Nov 21 '05 #1
1 3389
Hi Guys - I am moving this to the
microsoft.public.win32.programmers.networks forum as i thinks it better
suited.

Cheers

Sparky.
"Sparky" <sp****@microsoft.com> wrote in message
news:eE**************@TK2MSFTNGP14.phx.gbl...
Hi

I was wondering if someone can please enlighten me as to the best and most
approved way to connect and disconnect network drives in vb.net.

I have been using Mpr.dll API calls such as WNetCancelConnection2 and
WNetAddConnection2, but these seem to be very flakey with drive
disconnection (The drive conenction seems to be pretty good).

I would have through that Microsocft would have provided a simple class
you can call to take care of mapping network drives etc, but so far i have
only found API calls as the way to do this.

Has any one got a rock solid stable way to connect and disconnect network
drives in vb.net?

many thanks

Sparky.

Nov 21 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: banz | last post by:
Hello I have a problem to resolve: I wrote a Perlscript which caches data from a server (local on my machine) I would like to have a other connection to a remote server but I don't know how to...
1
by: BuddyWork | last post by:
Hello, I need to know how I can check if the drives on my machine are network drives and local drives via the .Net framework. For example my PC has the following drives C: Local D: Local N:...
2
by: yyy | last post by:
Hello, Can someone please tell me how I can connect to the Internet and/or disconnect from it using C#.NET ? I just want to open this window in order to connect:...
2
by: http://www.visual-basic-data-mining.net/forum | last post by:
Say i have declare a module for connection and two buttons... one button has the method connect() and the other has the method disconnect().... how do i actually connect after i had disconnect...
6
by: Nate | last post by:
I am in a slight predicament trying to determine the most efficient and effective way to connect/disconnect from a database within a business object (c# dll). I'm also keeping in mind the concept...
1
by: Maximus | last post by:
hi all, I want to kow if there is a way to connet a machine using a VPN client through vb.net or c# code. I have requirement where i need to copy file using VPN. Hence, I need to start the...
0
by: mamod20 | last post by:
Please advise, I have the following example and want to know the best way to use $dbh->disconnect; and $sth->finish; -------------- $sql_host="localhost"; $sql_dataname = "database";...
0
by: justsome_newbie | last post by:
Hello all, I was hoping one of you experts could help me. I'm trying to find a way to connect to a specific (I only have one) wireless network and then disconnect from it. Basically, I don't want...
0
by: danasegarane | last post by:
Hi all I want to map a network drive. If the user has access to that site then that path will map automatically. If the user doesnt have any rights the i need to get the username and pwd from the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.