在窗体上画一个名称为Drivel的驱动器列表框,一个名称为Dirl的目录列表框,一个名称为Filel的文件列表框,两个名称分别为Label1、Label2、标题分别为空白和“共有文件”的标签。编写程序,使得驱动器列表框与目录列表框、目录列表框与文件列表框同步变化,并且在标签Labell中显示当前文件夹中文件的数量。如图所示。
能够正确实现上述功能的程序是
A.PriVate Sub Dir1_Change() FilePath=Dir1.Path End Sub Private Sub Dirvel_Change() Dir1.Path=DriveDriveLabelCaption=FileListCount End Sub
B.Private Sub Dir1_Change() FilePath=Dir1.Path End Sub Private Sub Drivel_Change() DirPath=DriveDrive LabelCaption=FileList End Sub
C.Private Sub Dir1_Change() FilePath=Dir1.PathLabelCaption=File1.ListCount End Sub Private Sub Drivel_Change() Dir1.Path=DriveDriveLabelCaption=Fil1.ListCount End Sub
D.Private Sub Dir1_Change() File1.Path=Dir1.PathLabelCaption=FileList End Sub Private Sub Drivel_Change() Dir1.Path=DriveDriveLabelCaption=FileList End Sub