Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default generare a pause in a macro?

I have a macro that pulls info from a work book and then pastes it in to
another sheet, at this point I need the macro to stop running so that the
formula's I have in the sheet can update there cells before the macro resumes
and copy's the values from the updated cells and special pastes them to a
different sheet,

Currently the formulas are only running once the macro has stopped, and it
took me forever to figure this out!

Can anyone help? I really don't want to have to split the macro up in to two
separate ones

Can you help?

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 168
Default generare a pause in a macro?

Use this anytime you want the formulas to update.

Application.calculate

HTH,
Paul

"tigoda" wrote in message
...
I have a macro that pulls info from a work book and then pastes it in to
another sheet, at this point I need the macro to stop running so that the
formula's I have in the sheet can update there cells before the macro
resumes
and copy's the values from the updated cells and special pastes them to a
different sheet,

Currently the formulas are only running once the macro has stopped, and it
took me forever to figure this out!

Can anyone help? I really don't want to have to split the macro up in to
two
separate ones

Can you help?



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default generare a pause in a macro?

thank you, thats simple and fast,

"PCLIVE" wrote:

Use this anytime you want the formulas to update.

Application.calculate

HTH,
Paul

"tigoda" wrote in message
...
I have a macro that pulls info from a work book and then pastes it in to
another sheet, at this point I need the macro to stop running so that the
formula's I have in the sheet can update there cells before the macro
resumes
and copy's the values from the updated cells and special pastes them to a
different sheet,

Currently the formulas are only running once the macro has stopped, and it
took me forever to figure this out!

Can anyone help? I really don't want to have to split the macro up in to
two
separate ones

Can you help?




  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default generare a pause in a macro?

it doesn't appere to work,

iv placed it just after where i paste the rows in and before i begin to copy
the in for over but its still not working the cells do not update,

"PCLIVE" wrote:

Use this anytime you want the formulas to update.

Application.calculate

HTH,
Paul

"tigoda" wrote in message
...
I have a macro that pulls info from a work book and then pastes it in to
another sheet, at this point I need the macro to stop running so that the
formula's I have in the sheet can update there cells before the macro
resumes
and copy's the values from the updated cells and special pastes them to a
different sheet,

Currently the formulas are only running once the macro has stopped, and it
took me forever to figure this out!

Can anyone help? I really don't want to have to split the macro up in to
two
separate ones

Can you help?




  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,327
Default generare a pause in a macro?

Try

Application.calculate
DoEvents

HTH. Best wishes Harald

"tigoda" skrev i melding
...
it doesn't appere to work,

iv placed it just after where i paste the rows in and before i begin to

copy
the in for over but its still not working the cells do not update,

"PCLIVE" wrote:

Use this anytime you want the formulas to update.

Application.calculate

HTH,
Paul

"tigoda" wrote in message
...
I have a macro that pulls info from a work book and then pastes it in

to
another sheet, at this point I need the macro to stop running so that

the
formula's I have in the sheet can update there cells before the macro
resumes
and copy's the values from the updated cells and special pastes them

to a
different sheet,

Currently the formulas are only running once the macro has stopped,

and it
took me forever to figure this out!

Can anyone help? I really don't want to have to split the macro up in

to
two
separate ones

Can you help?








  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 415
Default generare a pause in a macro?

You can call the .Calculate method yourself on a Range, Worksheet or
Application.
Do that after your initial paste and before the copy.

NickHK

"tigoda" ...
I have a macro that pulls info from a work book and then pastes it in to
another sheet, at this point I need the macro to stop running so that the
formula's I have in the sheet can update there cells before the macro
resumes
and copy's the values from the updated cells and special pastes them to a
different sheet,

Currently the formulas are only running once the macro has stopped, and it
took me forever to figure this out!

Can anyone help? I really don't want to have to split the macro up in to
two
separate ones

Can you help?



  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default generare a pause in a macro?


Look for "Application.ontime" in the VBA help.

This example from VBA help:

This runs a procedure 15 seconds from now.

Application.OnTime Now + TimeValue("00:00:15"), "my_Procedure"

HTH
Jo

--
LFCFa
-----------------------------------------------------------------------
LFCFan's Profile: http://www.excelforum.com/member.php...fo&userid=3748
View this thread: http://www.excelforum.com/showthread.php?threadid=57420

  #8   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,593
Default generare a pause in a macro?

Does you code set the calculation mode to manual? Is so, set it back to
automatic at this time.

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"tigoda" wrote in message
...
I have a macro that pulls info from a work book and then pastes it in to
another sheet, at this point I need the macro to stop running so that the
formula's I have in the sheet can update there cells before the macro

resumes
and copy's the values from the updated cells and special pastes them to a
different sheet,

Currently the formulas are only running once the macro has stopped, and it
took me forever to figure this out!

Can anyone help? I really don't want to have to split the macro up in to

two
separate ones

Can you help?



  #9   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 26
Default generare a pause in a macro?

to be honest, im hashing through this making it up as i go along, my code is
a mix of bits or recorded macro and examples from online guides,

i have no idea where the calc would have been set to manual? how do i know?

"Bob Phillips" wrote:

Does you code set the calculation mode to manual? Is so, set it back to
automatic at this time.

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"tigoda" wrote in message
...
I have a macro that pulls info from a work book and then pastes it in to
another sheet, at this point I need the macro to stop running so that the
formula's I have in the sheet can update there cells before the macro

resumes
and copy's the values from the updated cells and special pastes them to a
different sheet,

Currently the formulas are only running once the macro has stopped, and it
took me forever to figure this out!

Can anyone help? I really don't want to have to split the macro up in to

two
separate ones

Can you help?




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Pause Macro 2 Ollie Excel Discussion (Misc queries) 3 June 15th 06 04:49 AM
Pause Macro cottage6 Excel Programming 2 April 14th 06 04:23 PM
Pause a macro? JohnnyJomp Excel Programming 4 March 10th 05 10:17 PM
Pause a Macro? Jimbo Excel Programming 2 October 14th 04 04:21 AM
Pause macro Bill Barclift Excel Programming 0 September 30th 03 09:22 PM


All times are GMT +1. The time now is 03:52 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"