Error handling in when mdb A calls mdb B

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I'm creating an application (mdb A) which runs sequentially procedures and
macros in other applications (mdb B, mdb C). mdb B and mdb C both contain
error handlers ("On Error goto ...), which will abort execution. If an error
occurs while running a procedure in mdb B, and mdb B aborts and returns to
mdb A, how can mdb A be aware of the abort and not move on to procedures in
mdb C?

For example, should I set a global variable or write to a table in mdb B,
which can be read by mdb A? I'm using syntax like app.docmd.runmacro
'myMacro_inB' and app.run 'myProcedure_inB'
 
Are B and C referenced by A (VBA, Tools, References), or are you
running separate application objects? If you are running a separate
application you need to create an interface to communicate errors.

For example, you might use DDE, or you might use a text file,
or you might write information to a table.

(david)
 
Back
Top