Group Abstract Group Abstract

Message Boards Message Boards

0
|
6.5K Views
|
1 Reply
|
1 Total Like
View groups...
Share
Share this post:

Get Slider range to change with Manipulate variable?

Posted 6 years ago
POSTED BY: Rob Holman
Posted 6 years ago

Maybe something similar to this?

Manipulate[
    If[dir != oldDir, a = -a; oldDir = dir];
    a,
    {{dir, 1, "direction"}, {1 -> "Positive", 2 -> "Negative"}},
    Dynamic@Switch[dir,
        1, Control@{{a, 0}, 0, 2, Appearance -> "Labeled"},
        2, Control@{{a, 0}, -2, 0, Appearance -> "Labeled"}
    ],
    {oldDir, 1, ControlType -> None},
    TrackedSymbols :> {dir, a}, AppearanceElements -> None
 ]
POSTED BY: Hans Milton
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard