Matalb App inputs dont work unless pressed?

3 views (last 30 days)
MKM on 19 Oct 2021
Answered: Cris LaPierre on 19 Oct 2021
I have this weird problem with my app where i have 5 check boxes 1,2,3,4,5
each one correlates to a filter for my tables. When i go into the app and click one and then apply the filter it crashes my app. however when i go in click them all then unlick them all and choes my filter the app works flawlessly?
Im so confused its like my app needs me to press all my inputs before to set a value to them, i cant just click one filter and hit apply, i have to click them all then unclick them and proced as normal..
Any help would be great
MKM on 19 Oct 2021
buy crash i mean shows up an error thats says
"Error using categorical/ismember (line 69)
Both inputs to ISMEMBER must be categorical arrays, or one of the inputs may be a scalar string or cell array of character vectors."
I get this error when i select 1 check box without touching the rest of them.However, when i click all the check boxes before i select an indivdual one like the same again it works. I cannot attach a copy at this time.

Sign in to comment.

Answers (1)

Cris LaPierre
Cris LaPierre on 19 Oct 2021
This sounds like an issue with how you process your data. Inspect what the code in your checkbox callback functions is doing to your data. It would appear that, originally, your inputs to ismember are different data types, but somehow as your callback functions execture, the datatypes are changed to be the same.
Sorry this is kind of vague, but the issue is specific to what your app is doing, and not with app designer in general. Without more specific information (data + code), this is the best I can do.


Find more on Develop Apps Using App Designer in Help Center and File Exchange




Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!