Effacer les filtres
Effacer les filtres

Error using uistyle for a table

5 vues (au cours des 30 derniers jours)
vedesh Mohit
vedesh Mohit le 12 Fév 2020
Commenté : vedesh Mohit le 12 Fév 2020
Hey I using guide on Matlab 2019b version. I am trying to run the following code but I am only getting the error (Undefined function or variable 'uistyle'). I am looking at the documentation to use uistyle, so why am I gettingthis error?
fig = uifigure;
fig.Position = [500 500 520 200];
uit = uitable(fig);
uit.Data = kdata;
uit.Position = [20 30 480 135];
s = uistyle('BackgroundColor','red');
addStyle(uit,s,'cell',[1,2]);
  3 commentaires
Walter Roberson
Walter Roberson le 12 Fév 2020
It works for me in R2019b. Could you re-check whether possibly you are using R2019a? The uistyle() function is new in R2019b.
vedesh Mohit
vedesh Mohit le 12 Fév 2020
Hey, Sorry yes it R2019a

Connectez-vous pour commenter.

Réponse acceptée

Walter Roberson
Walter Roberson le 12 Fév 2020
uistyle does not exist in r2019a or earlier, so you would need to upgrade to use it.
  1 commentaire
vedesh Mohit
vedesh Mohit le 12 Fév 2020
Thanks. I have upgraded and it works.

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Migrate GUIDE Apps 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!

Translated by