Matlab GUI Test
xl=get(handles.axes1, 'xlim'); yl = get(handles.axes1, 'ylim');
Working on multislides form
first go to openingFcn callback and set all uipanel visibile to off except the 1st one which is uipanel1. Here it is just one panel uipanel2
function gui1_OpeningFcn(hObject, eventdata, handles, varargin)
% This function has no output args, see OutputFcn.
% Choose default command line output for gui1
handles.output = hObject;
set(handles.uipanel2,'Visible','Off');
% Update handles structure
guidata(hObject, handles);
Now go to pushbutton1 (Next Button ) callback and set the uipanel1 visible to off and uipanel2 visible to on. That way when you click on next button, second one will appear and first will disappear. Remember you are just making it in invisible.. All the data which you have entered is as it were.. no harm to them.
function pushbutton1_Callback(hObject, eventdata, handles)
% hObject handle to pushbutton1 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
set(handles.uipanel2,'Visible','On');
set(handles.uipanel1,'Visible','Off');
Do the same for pushbutton2 callback but other way around
function pushbutton2_Callback(hObject, eventdata, handles)
% hObject handle to pushbutton1 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
set(handles.uipanel1,'Visible','On');
set(handles.uipanel2,'Visible','Off');