Bonjour,
j'ai un bouton dans mon GUI1 en cliquant dessus il va créer un GUI2 pour l'affichage des résultats voila mon code :

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
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
 
function resultats_callback(hObject, eventdata, handles)
 
% --- FIGURE -------------------------------------
handles.figure = figure(	'Tag', 'figure', ...
	'Units', 'characters', ...
	'Position', [59.8 12.6923076923077 137.6 40.1538461538462], ...
	'Name', 'resultats', ...
	'MenuBar', 'none', ...
	'NumberTitle', 'off', ...
	'Color', get(0,'DefaultUicontrolBackgroundColor'));
 
% --- AXES -------------------------------------
handles.axes2 = axes(	'Parent', handles.figure, ...
	'Tag', 'axes2', ...
	'UserData', [], ...
	'Units', 'characters', ...
	'Position', [13.8 4.46153846153847 100.2 32.3846153846154]);
 
% --- PUSHBUTTONS -------------------------------------
handles.pushbutton_Tracer = uicontrol(	'Parent', handles.figure, ...
	'Tag', 'pushbutton_Tracer', ...
	'UserData', [], ...
	'Style', 'pushbutton', ...
	'Units', 'characters', ...
	'Position', [122 7.61538461538463 13 1.69230769230769], ...
	'String', 'Tracer', ...
	'Callback', @pushbutton_Tracer_Callback);
 
% --- CHECKBOXES -------------------------------------
handles.checkbox_graph_A = uicontrol(	'Parent', handles.figure, ...
	'Tag', 'checkbox_graph_A', ...
	'UserData', [], ...
	'Style', 'checkbox', ...
	'Units', 'characters', ...
	'Position', [120 25 15 1.76923076923077], ...
	'String', 'Uxy Phi');
 
handles.checkbox_graph_B = uicontrol(	'Parent', handles.figure, ...
	'Tag', 'checkbox_graph_B', ...
	'UserData', [], ...
	'Style', 'checkbox', ...
	'Units', 'characters', ...
	'Position', [120 22 15 1.76923076923077], ...
	'String', 'Uxz Theta');
function pushbutton_Tracer_Callback(hObject,evendata, handles)
 
etat_A = get(handles.checkbox_graph_A,'Value');
etat_B = get(handles.checkbox_graph_B,'Value');
 
if etat_A
    plot(A(:,1),A(:,2),'LineStyle','-','LineWidth',2.5,'Color','green')
    hold on
end
 
if etat_B
    plot(B(:,1),B(:,2),'LineStyle','-','LineWidth',2.5,'Color','red')    
end
 
hold off
je ne comprend pas pourquoi il me donne ça :

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
 
??? Input argument "handles" is undefined.
etat_A = get(handles.checkbox_graph_A,'Value');
 
??? Error while evaluating uicontrol Callback