Function Varargout
Function Varargout
Function Varargout
DAN
PEMROGRAMAN
VOLUME BANGUN RUANG
DAN
GFARIK FUNGSI TRIGONOMETRI
OLEH
MEILINDA FAISOVI
140210101088
FKIP MTK
UNIVERSITAS JEMBER
EDIT
mfilename, ...
gui_Singleton, ...
@guidetemplate0_OpeningFcn, ...
@guidetemplate0_OutputFcn, ...
[] , ...
[]);
%
str2double(get(hObject,'String')) returns contents of edit1
as a double
% --- Executes during object creation, after setting all properties.
function edit1_CreateFcn(hObject, eventdata, handles)
% hObject
handle to edit1 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles
empty - handles not created until after all CreateFcns
called
% Hint: edit controls usually have a white background on Windows.
%
See ISPC and COMPUTER.
if ispc
set(hObject,'BackgroundColor','white');
else
set(hObject,'BackgroundColor',get(0,'defaultUicontrolBackgroundColor')
);
end
set(hObject,'BackgroundColor','white');
else
set(hObject,'BackgroundColor',get(0,'defaultUicontrolBackgroundColor')
);
end
T=str2double(get(myform.edit6,'string'));
Volume=P*L*T;
set(myform.edit8,'string',num2str(Volume));
case 3
myform = guidata(gcbo);
r=str2double(get(myform.edit7,'string'));
t=str2double(get(myform.edit6,'string'));
Volume=pi*r*r*t;
set(myform.edit8,'string',num2str(Volume));
otherwise
set(myform.edit8,'string','FOKUSDONG')
end
% hObject
% eventdata
% handles
% hObject
% eventdata
% handles
called
RUNNING
if nargout
[varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
gui_mainfcn(gui_State, varargin{:});
end
% End initialization code - DO NOT EDIT
% --- Executes just before tugasfix2 is made visible.
function tugasfix2_OpeningFcn(hObject, eventdata, handles, varargin)
% This function has no output args, see OutputFcn.
% hObject
handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles
structure with handles and user data (see GUIDATA)
% varargin
command line arguments to tugasfix2 (see VARARGIN)
% Choose default command line output for tugasfix2
handles.output = hObject;
% Update handles structure
guidata(hObject, handles);
% UIWAIT makes tugasfix2 wait for user response (see UIRESUME)
% uiwait(handles.figure1);
% --- Outputs from this function are returned to the command line.
function varargout = tugasfix2_OutputFcn(hObject, eventdata, handles)
% varargout cell array for returning output args (see VARARGOUT);
% hObject
handle to figure
% eventdata reserved - to be defined in a future version of MATLAB
% handles
structure with handles and user data (see GUIDATA)
% Get default command line output from handles structure
varargout{1} = handles.output;
% eventdata
% handles
called
%
str2double(get(hObject,'String')) returns contents of edit3
as a double
% --- Executes during object creation, after setting all properties.
function edit3_CreateFcn(hObject, eventdata, handles)
% hObject
handle to edit3 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles
empty - handles not created until after all CreateFcns
called
% Hint: edit controls usually have a white background on Windows.
%
See ISPC and COMPUTER.
if ispc
set(hObject,'BackgroundColor','white');
else
set(hObject,'BackgroundColor',get(0,'defaultUicontrolBackgroundColor')
);
end
RUNNING