Enable / disable EditText in APP Designer
24 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Khalala Mamouri
am 13 Jul. 2020
Kommentiert: Nitin Phadkule
am 14 Jun. 2021
Hello all !,
I am looking for a way to enable / disable a text field in app designer, while i am in the app
this is the code i am using,
if app.ControlStrategy.Value == Char('Condition')
set(app.Name_of_Texte_Field,'enable','off')
else
set(app.Name_of_Texte_Field,'enable','on')
end
I am looking for a way to do instantaniously while the app is runing.
thank you !
0 Kommentare
Akzeptierte Antwort
Mario Malic
am 28 Aug. 2020
Bearbeitet: Mario Malic
am 28 Aug. 2020
You might not see the FieldLabel in your component browser, right click there and tick the option 'Enable component labels...'
app.Name_of_Texte_Field.Enable = 0; % or 'off' or 'false' This will only disable the input field
app.Name_of_Texte_FieldLabel.Enable = 0; % This will disable the text that comes in front of the field
1 Kommentar
Nitin Phadkule
am 14 Jun. 2021
app.Name_of_Texte_FieldLabel.Editable = 0; will be better because app.Name_of_Texte_FieldLabel.Enable = 0;makes a transparent cover over text
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Develop Apps Using App Designer finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!