Feedback on status of Long Macro

  • Thread starter Thread starter Steve
  • Start date Start date
S

Steve

I have a macro with a great numbers of steps (basically making a local
copy of tables from a very slow ODBC database and doing some linking
and calculations at the same time) The macro is calling a series of
Make Table queries. As the macro takes over 5 minutes to run, it would
be comforting / informative to know where it was up to at any point

Is there a way I can show the progress as the macro runs eg which
query is being run. Perfect world would be a % complete bar but I
think I'm looking for too much.
TIA
Steve
 
Steve,

You could have a form, which is open when the form is running, with a
Label control on the form. Insert a SetValue action before each of the
existing actions in the macro, to change the Caption of the label, to
whatever comforting words you want.

Do you think that will do it?
 
Steve,

You could have a form, which is open when the form is running, with a
Label control on the form. Insert a SetValue action before each of the
existing actions in the macro, to change the Caption of the label, to
whatever comforting words you want.

Do you think that will do it?

--
Steve Schapel, Microsoft Access MVP





- Show quoted text -

Technique sounds OK but I have no idea how to actually do it. Any
details (in fact lots of details) would be appreciated - no big words
please, I'm new here :-)
Steve
 
Steve,

The level of delivery of your original post gave no hint that you are a
newbie. :-)

So, what exactly didn't you understand in what I wrote?

You already have a macro, and a macro is triggered by an Event. And in
the kind of scenario you described, this is typically an event borne by
a Form. For example, the Click event of a Command Button on a Form.
So, in the absence of you giving any information to the contrary, I will
continue to work on that assumption.

So, as I said... You have a form.

And on that form, you put a Label. Ok?

Now, go to your macro, and, to quote from my earler post, "insert a
SetValue action before each of the existing actions in the macro, to
change the Caption of the label".

What this means is this... You have a macro with a number of actions.
You have already made a macro, so I assume you know how to add Actions
to a macro. Put a SetValue action into the macro, before the existing
first action. Set the Arguments of the SetValue action like this...
Item: [NameOfTheLabel].[Caption]
Expression: "Now making a table called Fred"

I am not sure whether this is necessary, without testing it out, but I
reckon then you can put a RepaintObject action into the macro.

Ok, repeat the above steps for each of the existing actions in the macro.

So, your original macro is structured like this:

First action
Second action
Third action

And you want to make it like this:

SetValue
RepaintObject
First action
SetValue
RepaintObject
Second action
SetValue
RepaintObject
Third action

Let us know specifically what else you need to know.
 
Dear all,
I want to setvalue of a textbox with a query result.
Can i use the setvalue macro? how?
If i can't use it, then do you have any suggestion?

EggHeadCafe - .NET Developer Portal of Choice
http://www.eggheadcafe.com
 
SetValue is the macro action to write a specific value into a control on a
form, yes. You can use the DLookup function in an expression for the
Expression argument:

DLookup("FieldNameFromQuery", "QueryName")
 
Back
Top