问题
I have some VBA code that pulls stock prices from the web. My code uses an InternetExplorer object / document to do so. However, if possible, I would like to use a Microsoft Edge object / document instead.
In my current code:
I initialize an InternetExplorer variable:
Dim ie As InternetExplorer
Then I create an object:
Set ie = CreateObject("InternetExplorer.Application")
I'm wondering if it is possible to use a Microsoft Edge instead of Internet Explorer object / document in my code. Thank you in advance.
回答1:
Unfortunately Edge doesn't have an API VBA can use.
IE will continue to work.
Sources:
MSDN Social
SO
回答2:
Correction to the answer by destination-data:
IE will continue to work unless you actually uninstall it using windows features. Which was the case for one of my clients and the code that used
Set ie = CreateObject("InternetExplorer.Application")
broke. Be aware!
来源:https://stackoverflow.com/questions/34636368/is-it-possible-to-create-and-use-a-microsoft-edge-variable-object-in-vba