Last active
December 24, 2022 01:46
-
-
Save eggist77/49c5ce0182bc92b21e828e8b70e06f0c to your computer and use it in GitHub Desktop.
hatena: 1593831099
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Function getFilePathDlgIE() | |
Dim ie | |
Set ie = WScript.CreateObject("InternetExplorer.Application") | |
ie.Navigate "about:blank" | |
Do While ie.Busy = True And ie.ReadyState <> 4 'READYSTATE_COMPLETE = 4 | |
WScript.Sleep 100 | |
Loop | |
ie.document.write "<html><body><input type='file' id='selectFileDialog'></body></html>" | |
ie.document.getElementById("selectFileDialog").click | |
getFilePathDlgIE = ie.document.getElementById("selectFileDialog").Value | |
ie.Quit | |
Set objIE = Nothing | |
End Function |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment