SPECIAL OFFER        Order and save right now!
20% off with the 729824315 dicscount code for Ultimate Pack and any another product for Delphi from Greatis Programming!

⤷ Get list of network drives

To get list of all network drives, use WNetGetConnection function.

procedure TForm1.Button1Click(Sender: TObject);
var
  Drive: Char;
  PathStr: array[0..MAX_PATH] of Char;
  LPathStr: DWord;
begin
  LPathStr:=MAX_PATH;
  with Memo1.Lines do
  begin
    Clear;
    for Drive:='A' to 'Z' do
      if WNetGetConnection(
        PChar(''+Drive+':'), 
        PathStr, 
        LPathStr)=NO_ERROR then Add(Drive);
    if Count=0 then
      Add('You have not network drives');
  end;
end;
More for developers
Databases for Amazon Associates
Amazon Categories
Amazon Nodes