Macros vs. VBA: Another look
I previously posted about Macro & VBAs. At the time most of the new stuff we were doing was not public (Beta1 was not out), so I could not talk about all the new macro functionality.
Now that some of you had the chance to play around with Beta1 and that I posted some comments about these new features, it's worth reconsidering where we stand on the Macros vs. VBA debacle.
At least two of the downsides of macros are at the very least greatly reduced (if not simply gone): error handling and variables. One advantage is also clearly in the side of macros: the capability of having safe un-signed "code".
So, how do we fare?
I think the answer is clearer now: macros have a niche of being used as glue and simple action-driven code for databases that might be run with code disabled. Macros do not and will not replace VBA in any way, and if you are writing huge macros (say, 10-20 actions), you might be overdoing it.
I know this sounds like the politically correct response (c'mon, one of them *must* suck…), but this is exactly the intent we had when introducing these changes. We don't expect or would want anyone to migrate VBA code to Macros (as I heard a customer ask once when we showed this), but simply be able to have enough functionality with macros to be able to do small things in a clear and concise manner and leave VBA to be the bigger hammer for the bigger problems.
Comments
- Anonymous
May 04, 2006
The comment has been removed - Anonymous
May 04, 2006
Good question. I probably should've mentioned this :)
This behavior (quitting on error) is changed in Access 2007, if you are using OnError to either skip over error (OnError Next) or if you are jumping to a label (OnError Macro Name).
So if you still have OnError Halt we will exit on errors.