Converting Macros to VB

E

Ed Hawley

Is there a good way to convert macros to VB when you do not remember how to
program in VB. I am continually running into problems with the macros,
because of security issues, with the systems on which the database is run. I
would like to change them and eliminate the problem. Any suggestions would
help.

Thanks!
Ed
 
A

Allen Browne

Access can convert macros to VBA code for you.

With a form open in design view, go to Tools | Macors.
Or select the macro in the Database window, and go to File | Save As.

Look under help for "convert macors" for more info.

The converted macro does have error handling, so it's better than the macro,
but it's still pretty woeful compared with well-designed code.
 
L

Larry Daugherty

You can't get there from here....

I believe that Access provides a converter that moves you along the
way. I haven't written any Access Macros since it became available so
your mileage may vary...

The warnings you get really have to do with VBA code as much as any
Access Macros. In all other platforms, VBA code is referenced as
"macro".

A piece of trivia: The original "macro" implementation was from
Digital Equipment Corporation (DEC) in its PDP-11, and up, assembler
languages. The software engineer could create the low level referents
once, creating incredibly deep nested macros, and refer to them many
times in the source code with a single line each time. The actual
assembler (compiler) then inserted the entire source code into the
object code each time it was called. A source file of just a few
pages might generate a listing file several inches deep. I believe
that every programming language that has claimed to be "macro" ever
since then is trying to claim similar power and expandability. None
has come even remotely close in exactly the same way.

HTH
 
E

Ed Hawley

Thanks Allen,

I will give it a try.

Ed
Allen Browne said:
Access can convert macros to VBA code for you.

With a form open in design view, go to Tools | Macors.
Or select the macro in the Database window, and go to File | Save As.

Look under help for "convert macors" for more info.

The converted macro does have error handling, so it's better than the
macro, but it's still pretty woeful compared with well-designed code.
 
E

Ed Hawley

Thanks Larry,

Interesting history of the Macro. Makes it seem that even if I do the
conversions, I may still get the errors from VBA

Thanks!
Ed
 
Top