writting error meesage
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hello how can i write code to print message my answer is:
if r > 0.49 sPrintf('the person is accepted.'); else error('the person is unccepted or not exist.') end;
please correct my answer
thanks
0 commentaires
Réponse acceptée
Oleg Komarov
le 30 Mai 2011
if r > 0.49
sprintf('The person is accepted.')
else error('The person is unccepted or not exist.')
end
0 commentaires
Plus de réponses (1)
Philip
le 30 Mai 2011
try using the 'msgbox()' function:
ie.
if r > 0.49
disp('The person is accepted')
else
msgbox('The person is not accepted','An error has occurred','error')
end
See "doc msgbox" for more details.
Voir également
Catégories
En savoir plus sur Spectral Measurements dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!