return UNC path

Posted on 2005-04-19
Last Modified: 2008-01-09
How would we convert a local path to an UNC-path in VB.NET? (without using an API). TIA....
Question by:unicorn1824
    LVL 34

    Accepted Solution

    YEs i know its api ->,293820,sid8_gci954149_tax293674,00.html

    I dont belive there is a native way..

    LVL 1

    Assisted Solution

    You can use COM Object: FileSystemObject

    In the IDE click Project > Add Reference > COM tab – select Microsoft Scripting Runtime


    Dim FSO As New FileSystemObject
    Dim strShare As String

    strShare = FSO.GetDrive("J:\").ShareName

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    I think the Typed DataTable and Typed DataSet are very good options when working with data, but I don't like auto-generated code. First, I create an Abstract Class for my DataTables Common Code.  This class Inherits from DataTable. Also, it can …
    Introduction As chip makers focus on adding processor cores over increasing clock speed, developers need to utilize the features of modern CPUs.  One of the ways we can do this is by implementing parallel algorithms in our software.   One recent…
    This video is in connection to the article "The case of a missing mobile phone (". It will help one to understand clearly the steps to track a lost android phone.
    Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

    759 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    11 Experts available now in Live!

    Get 1:1 Help Now