Bonjour,
J'ai un petit soucis concernant le callback des popupmenu
J'ai une erreur qui concerne à mon avis la ligne en rouge mais je ne comprend pas pourquoi.
Si quelqu'un pouvait m'aider ça serait sympa. J'ai cherché un peu partout dans l'aide et sur le net mais je vois pas pourquoi.

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
function callbacktestboucle(src,evt)   

         val1=get(findobj(gcbo,'tag','boucle1'),'Value')
         val2=get(findobj(gcbo,'tag','boucle2'),'Value');
         val3=get(findobj(gcbo,'tag','boucle3'),'Value');
         val4=get(findobj(gcbo,'tag','boucle4'),'Value');
         
         str1=get(findobj(gcbo,'tag','boucle1'),'String');
         str2=get(findobj(gcbo,'tag','boucle2'),'String');
         str3=get(findobj(gcbo,'tag','boucle3'),'String');
         str4=get(findobj(gcbo,'tag','boucle4'),'String');
    
     
         if(strcmp(cellstr(str1{val1}),'frequence')==true)   
             set(findobj(gcbf,'tag','boucle2'),'String',{'angle','polarisation','commutation'});
             set(findobj(gcbf,'tag','boucle3'),'String',{'angle','polarisation','commutation'});
             set(findobj(gcbf,'tag','boucle4'),'String',{'angle','polarisation','commutation'});
             
         elseif(strcmp(cellstr(str1{val1}),'frequence')==true && strcmp(cellstr(str2{val2}),'angle')==true)             set(findobj(gcbf,'tag','boucle3'),'String',{'polarisation','commutation'});
             set(findobj(gcbf,'tag','boucle4'),'String',{'polarisation','commutation'});
         end
L'erreur :
Cell contents reference from a non-cell array object.