Discussion:
Is it possible to enable/disable guidata items depending on other item values?
Josh Burnett
2012-07-05 19:08:59 UTC
Permalink
I am trying to construct a configuration dialog using guidata. I have the
basic dialog working fine, but I would really like to be able to enable or
disable some of the fields based on the value of one of the other fields.

For instance, I would like the user to be able to enable a feature using a
checkbox. There is another field whose value modifies the feature's
behavior. This last value is only relevant if the feature is enabled, so I
would like to disable the input if the checkbox is not checked.

I have looked through the documentation, and I don't see any examples that
work like this. Is this possible with guidata, or do I need to make my own
dialog?

Many thanks,

Josh
Josh Burnett
2012-07-05 19:11:27 UTC
Permalink
D'oh! No sooner do I make my post than I see the 'activable data sets.' I
must have missed it (it had been awhile since I had looked through the
documentation when I last tackled this problem).

Sorry to clutter up the list.

Josh
Post by Josh Burnett
I am trying to construct a configuration dialog using guidata. I have the
basic dialog working fine, but I would really like to be able to enable or
disable some of the fields based on the value of one of the other fields.
For instance, I would like the user to be able to enable a feature using a
checkbox. There is another field whose value modifies the feature's
behavior. This last value is only relevant if the feature is enabled, so I
would like to disable the input if the checkbox is not checked.
I have looked through the documentation, and I don't see any examples that
work like this. Is this possible with guidata, or do I need to make my own
dialog?
Many thanks,
Josh
Loading...