Mapping network drive

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Slawek

    #1

    Mapping network drive

    Hello,

    In my application (WinForm) I need to read data from files located on other
    computers. I know passwords and user names requied to map these natwork
    drives but I don't know how to map it programmaticaly from my application.
    Do you have any ideas? Thanks for any help.

    Regards
    Slawek


  • Nicholas Paldino [.NET/C# MVP]

    #2
    Re: Mapping network drive

    Slawek,

    You will have to use the WNetAddConnecti on function (or the number 2, or
    3 versions of it) in order to map a network drive. You will have to call
    this function through the P/Invoke layer.

    Hope this helps.


    --
    - Nicholas Paldino [.NET/C# MVP]
    - mvp@spam.guard. caspershouse.co m

    "Slawek" <slawek7302@wp. pl> wrote in message
    news:OBK7vibuDH A.1888@TK2MSFTN GP10.phx.gbl...[color=blue]
    > Hello,
    >
    > In my application (WinForm) I need to read data from files located on[/color]
    other[color=blue]
    > computers. I know passwords and user names requied to map these natwork
    > drives but I don't know how to map it programmaticaly from my application.
    > Do you have any ideas? Thanks for any help.
    >
    > Regards
    > Slawek
    >
    >[/color]


    Comment

    Working...