>GETDIR() doesn't return remoted mapped drives that are mapped, but not connected, as illustrated by their icon having a red X thru it in Explorer. This happens when the computer is started before the computer with the mapping is started before the computer with the drive.
>
>I'd like to show the drive in GETDIR(), by forcing the connection (if possible). If the drive really isn't available, then of course, it shouldn't show.
>
>TIA.
Hi Nancy.
This API function queries the mapped drive and supposedly tests the connection. I'm not sure it will force it, but you can give it a try
Regards
Jose
DECLARE Long WNetGetConnection in WIN32API;
STRING @lpzLocalName, ;
STRING @lpzRemoteName, LONG @lpnSize
lcLocalName = "T:"
lcRemoteName = Space(255)
lnSize = 255
lnRet = WNetGetConnection( @lcLocalName, @lcRemoteName, @lnSize)