MathGroup Archive 2009

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Another Monitor problem

  • To: mathgroup at smc.vnet.net
  • Subject: [mg104793] Re: Another Monitor problem
  • From: Albert Retey <awnl at gmx-topmail.de>
  • Date: Tue, 10 Nov 2009 05:59:13 -0500 (EST)
  • References: <hd6dea$q31$1@smc.vnet.net>

Hannes Kessler schrieb:
> Hello,
> 
> is it possible to monitor the intermediate state of a calculation with
> Monitor inside the action argument of a Button? The following Monitor
> example without a Button works:
> 
> Monitor[Do[i, {i, 10^7}],  Refresh[Pause[0.03]; i, UpdateInterval ->
> 0.01]]
> 
> However, when the calculation is started by a Button only the final
> result is displayed, the intermediate state of the calculation is not
> monitored:
> 
> Button["Run",  Monitor[Do[i, {i, 10^7}],   Refresh[Pause[0.03]; i,
> UpdateInterval -> 0.01]]]
> 

I think it is as often the Method option which will make the Button do
what you want:

Button["Run",
 Monitor[Do[i, {i, 10^7}],
  Refresh[Pause[0.03]; i, UpdateInterval -> 0.01]],
 Method -> "Queued"]

hth,

albert


  • Prev by Date: Re: Complex solutions to simple equations
  • Next by Date: Re: Complex solutions to simple equations
  • Previous by thread: Another Monitor problem
  • Next by thread: incompatibilities