Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 57
Default awaiting the execution of code...

I have a Selection.FormulaArray line of code that has to wait on a link to
supply data to compute the array formula and populate the cells it controls.

Well, from those data, I calculate min and max cell values to carry over to
a chart to define the limits on the Y-axis.

My issue is the code executes down and to the point where it wants those min
and max values, but they are not available... yet... so I get an error
message.

I have tried Application.Wait Now + TimeValue ("00:00:15") and other similar
tactics hoping to slow the execution of the code until the
Selection.FormulaArray grabs its data and performs the calculations, but in
every case, whatever method I employ seems to stop the calculation process,
so I gain no advantage by attempting to sort of pause the code execution
until the data are ready for the min and max variables.

What a mess... I am looking for some way to work around this. My thanks
in advance for any suggestions.

B. Reid


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 638
Default awaiting the execution of code...

Have you tried placing DoEvents before the chart processing?
Brad wrote:
I have a Selection.FormulaArray line of code that has to wait on a link to
supply data to compute the array formula and populate the cells it controls.

Well, from those data, I calculate min and max cell values to carry over to
a chart to define the limits on the Y-axis.

My issue is the code executes down and to the point where it wants those min
and max values, but they are not available... yet... so I get an error
message.

I have tried Application.Wait Now + TimeValue ("00:00:15") and other similar
tactics hoping to slow the execution of the code until the
Selection.FormulaArray grabs its data and performs the calculations, but in
every case, whatever method I employ seems to stop the calculation process,
so I gain no advantage by attempting to sort of pause the code execution
until the data are ready for the min and max variables.

What a mess... I am looking for some way to work around this. My thanks
in advance for any suggestions.

B. Reid


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
Pausing a Macro awaiting user input jayklmno Excel Programming 6 July 3rd 07 03:22 AM
Code Execution Error Craig Excel Programming 1 August 29th 06 09:28 AM
code execution has been interrupted Who I Am Excel Programming 1 February 2nd 06 11:54 AM
code execution has been interrupted François Excel Discussion (Misc queries) 1 February 18th 05 11:06 PM
Why does code execution stop? HELP! Damian Excel Programming 2 February 16th 05 06:41 PM


All times are GMT +1. The time now is 07:22 PM.

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

About Us

"It's about Microsoft Excel"