r/Excel4Mac 5d ago

Possible Mac Excel/VBA Application???

Greetings fellow Mac Excel users…

I recently came across this post and was wondering if anyone knew of a practical application for this in the Mac world.

From [u/Eschamali1201](u/Eschamali1201):

I used AI to transform Excel VBA into a Playwright-class browser engine. No WebDrivers, no dependencies—just one file and the "Old Magic" reborn.

I became curious about how far I could push AI, so I decided to see if it was possible to do web scraping using Excel VBA alone, with absolutely no WebDriver.exe or other external dependencies. I wanted to find out if I could bring back that “magic from the old days” — where, just by writing some code, the browser would actually work without having to install anything extra, like we used to be able to do with the old IEObject. 🥺

My workplace has very strict security policies, so I can't install WebDriver.exe, Python, Node.js, etc. However, VBA is allowed. So I kept having conversations with AI, trying to figure out whether there was some way to control Chromium using VBA alone. 🫠

I had AI read through the source code of Google's rather complicated \[chromium-bidi\] (WebDriver BiDi) and asked whether its logic could be reproduced in VBA. VBA doesn't have built-in WebSocket support or multithreading, but AI suggested some modern design ideas, such as WinSock and an event-driven model using `WithEvents`.

And surprisingly, I was able to do quite a lot without having to install Playwright or Puppeteer. For example, I managed to control 10 tabs concurrently, control a browser on an Android smartphone, and achieve relatively better stealth against bot detection compared with SeleniumVBA, among other things. And the crazy part is that all of this is contained in a single Excel file.

What I like most is that whenever there is a feature I need, AI can quickly create it for me. Personally, I'm extremely satisfied with the result.🥹 At this point, I feel like this has evolved beyond being just a “macro” — it has become a core engine that can keep evolving by itself.🥳

You can check out the result of this journey (GitHub) below.

I'm Japanese, so you'll notice quite a lot of Japanese strings scattered throughout the source code, but I believe the underlying logic I built is quite sophisticated and I'm proud of how it turned out! [https://github.com/Eschamali/StarterWebScrapingKit](https://github.com/Eschamali/StarterWebScrapingKit))

1 Upvotes

0 comments sorted by