Noooo! It can't be true!
I tried sooo many things that this was probably inevitable. I was twitchy that csvpath might be a system variable (I know, right? but I was running out of sensible things to try), so I changed it, with Saturday-approprate incompetence.
So thank you, hrlngrv, for spotting this. I introduced that error about an hour before I posted the message, at precisely the time when I started trying to write to the Library - Data folder.
So the current state of play is:
- can save CSV files, but only to a directory that Apple really doesn't want you to see, (given that it requires magic tricks in Finder - Press Option, click menu item Go to access the Library folder.)
- can create a folder inside Data and save there. There must be a trailing slash on the path in the macro.
- xlsx files will generate a GRANT ACCESS dialog when you save them to the location of your choice, but CSV files do not.
Can anyone explain why this restriction is in place?
To save all the option-Go clicking, Finder will let you drag the Data directory to the sidebar. Then, of course, you have a sidebar entry named "Data" which is a bit obscure. I created a folder "TaxCSVs" in Data and dragged that to the Sidebar. This provides convenient access to the CSV's after export without requiring me to remember obscure paths.
As a public service, this is the minimal macro required to save the CSV: