Can VBA code be written to perform actions on any Excel file?
When I create a project in Visual Studio, it asks for an Excel file
You can do that in VB.Net too. Just make a regular project. (comment by @SLaks)
This worked for me very well and was exactly what I was looking for.
The very descriptive answer posted by @ErikEidt
I haven't tried this, but it seems like a good and alternative way of getting macros to work.