>I need to know how to get the path of a logical drive.
>
>If I connect \\server\C to F: acrros the network neigborhood how can I get the path using the logical drive.
>
>I can do this with a MS-DOS command line: Net use F: \\Server\C /yes
>
>When I double click in My PC icon I see C in "Server" (F:).
>
>I think must exist an api call to get it.
Hi Jose,
I think what you're referring to the the server/volume. If so, the following will probably get the information you need:
DECLARE INTEGER WNetGetConnection IN Win32API;
STRING @lpszLocalName, STRING @lpbuffer, INTEGER @lnbufsize
lcbuffer = SPACE(200)
lnsize = LEN(lcbuffer)
IF WNetGetConnection(@lcdevice, @lcbuffer, @lnsize) = 0
lcbuffer = LEFT(lcbuffer, AT(CHR(0), lcbuffer) - 1)
ENDIF
George
Ubi caritas et amor, deus ibi est