可以使用其Drive和Directory域,例如:
driveComboBox1.Drive := 'c';
directoryListBox1.Directory := 'c:\winnt';

解决方案 »

  1.   

    procedure TForm1.DriveComboBox1Change(Sender: TObject);begin
      DirectoryListBox1.Drive := DriveComboBox1.Drive;
      FileListBox1.Drive := DriveComboBox1.Drive;
      FileListBox1.Directory := DirectoryListBox1.Directory;end;
      

  2.   

    procedure TForm1.DriveComboBox1Change(Sender: TObject);begin
      DirectoryListBox1.Drive := DriveComboBox1.Drive;
      FileListBox1.Drive := DriveComboBox1.Drive;
      FileListBox1.Directory := DirectoryListBox1.Directory;end;