View Single Post
  #8   Report Post  
Posted to microsoft.public.excel.programming
brian brian is offline
external usenet poster
 
Posts: 22
Default VBA codes for macro to continue

As I use several other Excel 4 macro programs, I don't want to delete this
tool-bar as mentioned in your suggested article. I can physically create or
customize my own tool-bar and place a command button in it. I don't need the
"pause". What I need is a set of VBA codes "to resume" after the pause. This
then will allow me to use other similar Excel 4 macro programs under Office
Excel 2003 environment. Can you tell me where I can find this information?
Thanks.

Brian


"Vasant Nanavati" <vasantn *AT* aol *DOT* com wrote in message
...
Brian, I think I understood quite well what you were asking. Here's what
Microsoft says, although the terminology might be out of date now:

"In Visual Basic, Applications Edition, there is no built-in equivalent
for
the MS Excel 4.0 PAUSE() macro function. The Visual Basic code in this
article provides an alternative.

"You might want to use this code to pause execution of your macro while a
user enters data directly in a sheet or manipulates menus."

.................................................. ....................

"If you have a single procedure within which you need to pause execution
until the user desires to resume execution, split your sub procedure into
two halves."

http://support.microsoft.com/kb/q131847/

--

Vasant

"Brian" wrote in message
...

"Vasant Nanavati" <vasantn *AT* aol *DOT* com wrote in message
...
Perhaps you could split the macro into two, and run the second part on

the
button click. I honestly don't remember much about the old macros any

more
... the memory is going ;-).


Nooooo! You misunderstood what I am trying to tell you. I'm not asking
for
the old macro codes. They work fine under older version of Excel. The
program even runs ok under Office 2003 Excel. All I'm after is a new

button
assigned to a new set of VBA codes running Office 2003 Excel, that tells

the
program to continue with its macro execution. If you now re-read my

original
post it will make sense.

Brian





"Brian" wrote in message
...
Hi Vasant/Mark

I'm trying to use an older Excel (.xlm) macro program which works fine
with
MS Office 2003 Excel, except after the point where the program pauses

to
accept user inputs (like name, date, etc.). To continue, the user then
activates the continue button to enable the program to complete its
execution. This button now doesn't work as the current version of
Excel
doesn't understand it. Can you outline for me the new command code(s)

to
assign this button to, or another way around it other than the long
way
as
suggested below? Thanks.

Brian

One suggestion:
Add this line to the program after "=Pause()":
=Activate("XYZ.xls") (replace XYZ with the worksheet name)
Then execute, ToolsMacroMacros....Run (from that line)



"Brian" wrote in message
...
Am not a programmer. I would like to create a button so that the
running
macro will continue after a pause. Can someone help me with just
that
few
lines of codes.

TIA
Brian