www.pudn.com > Closid30.rar > CLERRDIA.M, change:1998-05-19,size:887b


function clerrdia(errtxt,bip) 
% clerrdia(errtxt,bip) 
% 
% Open window for error dialog 
 
% errtxt    String containing the error message text 
% bip       Beep (1) or not (0), default not 
 
% Functions called: clsetcol 
 
% 21-05-1996 
% (c) Douwe de Vries, Edwin van Donkelaar, Paul Van den Hof 
% Mechanical Engineering Systems and Control Group 
% Delft University of Technology 
% Last update: 19-05-1998. 
 
% Colors 
[frmcol,txtcol,edicol,pshcol,radcol,axscol,c7,c8,c9,c10,... 
    modcol,edtcol,pubcol,putcol,chbcol,chtcol,txbcol,pstcol]=clsetcol; 
 
% Defaults 
if nargin<2, bip=0; end 
 
% Close all previous error dialogs 
h=findobj('name','Error Dialog'); 
close(h) 
 
% Open window 
%dialog('Style','error','TextString',errtxt,'BackgroundColor',edicol,... 
%       'Name','Error Dialog','Replace','off'); 
errordlg(errtxt,'Error Dialog') 
 
% beep 
if bip==1, beep; end