Windows Server 2003
No
Windows XP
Yes
Windows 2000
No
Windows NT 4.0
No
Windows 98
No
Script Code
代码如下:
Set objDialog = CreateObject("UserAccounts.CommonDialog")
objDialog.Filter = "VBScript Scripts|*.vbs|All Files|*.*"
objDialog.FilterIndex = 1
objDialog.InitialDir = "C:Scripts"
intResult = objDialog.ShowOpen
If intResult = 0 Then
Wscript.Quit
Else
Wscript.Echo objDialog.FileName
End If