Announcement

Collapse
No announcement yet.

Finding servername for mapped drive?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Anthony Stout
    replied
    Awesome - works perfect.

    Leave a comment:


  • Adam J. Drake
    replied
    Another possibility, take a look at Pierre Belisle's posting here: http://www.powerbasic.com/support/pb...t=21210&page=2

    Leave a comment:


  • George Bleck
    replied
    Have a look at NetUseGetInfo or WNetGetConnection, here is a PB example.

    Code:
     
     
    #INCLUDE "win32api.inc"
     
    FUNCTION PBMAIN( )
     LOCAL StrPath AS STRING
     strPath = SPACE$( %MAX_PATH )
     WNETGETCONNECTION "P:", BYVAL STRPTR( strPath ), LEN( strPath )
     MSGBOX strPath
    END FUNCTION

    Leave a comment:


  • Anthony Stout
    started a topic Finding servername for mapped drive?

    Finding servername for mapped drive?

    I have a mapped drive that I need to be able to find the servername for - meaning if x: is mapped to \\myserver\test, I need the script to find the "myserver" part of the mapping.

    Is there a built in statment that can handle this task?

    Thank you.
Working...
X