Vbscript / User Interaction / Browse For File Dialogue Box
Uses the Windows explorer browse file dialogue box to select a file. The explorer view can limit the types of file displayed for selection. Set objDialog = CreateObject("UserAccounts.CommonDialog") objDialog.Filter = "All Folders|*.*" objDialog.InitialDir = "C:" intResult = objDialog.ShowOpen If intResult = 0 Then Wscript.Quit Else Wscript.Echo objDialog.FileName End If
Please note that a disclaimer applies to any code on this page.
|