I have been working on a database and wanted to do it using purely VBA codes. However, I was told by a friend that its more secure for me to use macros because the database will be used on a local network. I am not very verse in the use of macro but if its better way for the database then let me know the pros and cons. and if I decide to later migrate the database to sql will there be problems. the first database I did had a generated errors with with older versions of access which created my inclination to VBA. I know this question is made to sound complex but I just basically want some guidance as to pros and cons of VBA vs Macros in access.
In most of the more professional Access applications (not web apps) I've worked on, we only used one macro and it was named AutoExec. When you create a Macro and name it AutoExec, it's the very first thing that will run (even before the form you have set as your main form). This macro is usually used do things like hide UI elements, establish connection strings, link tables, and popup a login form, most of which probably has to be done by calling VBA functions from the macro.
Macros have some built-in functionality that eliminates the need for code, plus you can build functionality quicker with macros. For example, if I want to open a database and run 10 Create Table queries, I can create a macro to do that with just a few clicks. I can do the same with VBA, but it takes longer and requires a much better working knowledge of VBA. I am not aware of a single operation that a macro can do and VBA code can't.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With