In order to control the Internet Explorer web browser, VBA needs 2 additional reference libraries:
Microsoft HTML Object Library and Microsoft Internet Controls
Here’s how to add them…
Open the VBA Editor, and click Tools > References…

Make sure these 4 References are active by default:
- Visual Basic for Applications
- Microsoft Excel xx.x Object Library
- OLE Automation
- Microsoft Office xx.x Object Library

Scroll down a tick these 2 web-related References:
- Microsoft HTML Ojbect Library
- Microsoft Internet Controls

Resulting in…
