Re: How Can I Include a Button in a Manipulate
- To: mathgroup at smc.vnet.net
- Subject: [mg120442] Re: How Can I Include a Button in a Manipulate
- From: Heike Gramberg <heike.gramberg at gmail.com>
- Date: Fri, 22 Jul 2011 19:47:01 -0400 (EDT)
- References: <201107220107.VAA16785@smc.vnet.net>
You could do something like
Manipulate[Module[{p},
q; p = RandomInteger[max, {height, width}];
p // TableForm],
{{width, 3}, Range[8], SetterBar},
{{height, 3}, Range[8], SetterBar},
{{max, 4}, Range[10], SetterBar},
{{q, False}, ControlType -> None},
Control[Button["Regenerate", q = Not[q]]]
]
Heike
On 22 Jul 2011, at 02:07, Gregory Lypny wrote:
> Hello everyone,
>
> I have a Manipulate that generates a random integer or integers
> depending on the user's choice of parameters in a number of setter
> bars. I'd like to include a button in the Manipulate's output pane
> that allows the user to generate a new result by generating a new random
> number while keeping all of the parameters in the setter bar the same.
> Can that be done?
>
>
> Regards,
>
> Gregory
>
- References:
- How Can I Include a Button in a Manipulate
- From: Gregory Lypny <gregory.lypny@videotron.ca>
- How Can I Include a Button in a Manipulate