Hola, resulta que tengo que realizar una simple operación matemática en la que el usuario ingresa dos valores mediante dos controles Edit y luego obtengo la respuesta al pulsar un botón. Pero no me da el siguiente error cuando pulso el botón:
at line 4 of function %h_e ( C:\PROGRA~1\SCILAB~1.1\modules\graphics\macros\%h_e.sci line 16 )
in builtin calc_callback ( F:\NUBE\CUN\Antenas y lineas de transmisión\Calculadora antena\antena2.sce line 25 )
get: The handle is not or no more valid.
Agradezco cualquier ayuda
at line 4 of function %h_e ( C:\PROGRA~1\SCILAB~1.1\modules\graphics\macros\%h_e.sci line 16 )
in builtin calc_callback ( F:\NUBE\CUN\Antenas y lineas de transmisión\Calculadora antena\antena2.sce line 25 )
get: The handle is not or no more valid.
Código [Seleccionar]
// This GUI file is generated by guibuilder version 4.2.1
//////////
f=figure('figure_position',[2596,204],'figure_size',[697,735],'auto_resize','on','background',[33],'figure_name','Graphic window number %d','dockable','off','infobar_visible','off','toolbar_visible','off','menubar_visible','off','default_axes','on','visible','off');
//////////
//handles.dummy = 0;
handles.antena=uicontrol(f,'unit','normalized','BackgroundColor',[-1,-1,-1],'Enable','on','FontAngle','normal','FontName','Tahoma','FontSize',[12],'FontUnits','points','FontWeight','normal','ForegroundColor',[-1,-1,-1],'HorizontalAlignment','left','ListboxTop',[],'Max',[1],'Min',[0],'Position',[0.2073529,0.3419540,0.5785294,0.5201149],'Relief','default','SliderStep',[0.01,0.1],'String','F:\NUBE\CUN\Antenas y lineas de transmisión\Calculadora antena\antena.png','Style','image','Value',[1,1,0,0,0],'VerticalAlignment','middle','Visible','on','Tag','antena','Callback','antena_callback(handles)')
handles.calc=uicontrol(f,'unit','normalized','BackgroundColor',[-1,-1,-1],'Enable','on','FontAngle','normal','FontName','Tahoma','FontSize',[12],'FontUnits','points','FontWeight','normal','ForegroundColor',[-1,-1,-1],'HorizontalAlignment','center','ListboxTop',[],'Max',[1],'Min',[0],'Position',[0.1352941,0.2428161,0.2147059,0.0603448],'Relief','default','SliderStep',[0.01,0.1],'String','UnName2','Style','pushbutton','Value',[0],'VerticalAlignment','middle','Visible','on','Tag','calc','Callback','calc_callback(handles)')
handles.fv=uicontrol(f,'unit','normalized','BackgroundColor',[-1,-1,-1],'Enable','on','FontAngle','normal','FontName','Tahoma','FontSize',[12],'FontUnits','points','FontWeight','normal','ForegroundColor',[-1,-1,-1],'HorizontalAlignment','left','ListboxTop',[],'Max',[1],'Min',[0],'Position',[0.4073529,0.25,0.2897059,0.0502874],'Relief','default','SliderStep',[0.01,0.1],'String','UnName3','Style','edit','Value',[0],'VerticalAlignment','middle','Visible','on','Tag','fv','Callback','')
handles.fv=uicontrol(f,'unit','normalized','BackgroundColor',[-1,-1,-1],'Enable','on','FontAngle','normal','FontName','Tahoma','FontSize',[12],'FontUnits','points','FontWeight','normal','ForegroundColor',[-1,-1,-1],'HorizontalAlignment','left','ListboxTop',[],'Max',[1],'Min',[0],'Position',[0.4,0.1508621,0.3,0.0502874],'Relief','default','SliderStep',[0.01,0.1],'String','UnName4','Style','edit','Value',[0],'VerticalAlignment','middle','Visible','on','Tag','fv','Callback','')
handles.result=uicontrol(f,'unit','normalized','BackgroundColor',[-1,-1,-1],'Enable','on','FontAngle','normal','FontName','Tahoma','FontSize',[12],'FontUnits','points','FontWeight','normal','ForegroundColor',[-1,-1,-1],'HorizontalAlignment','left','ListboxTop',[],'Max',[1],'Min',[0],'Position',[0.5191176,0.6810345,0.2044118,0.0632184],'Relief','default','SliderStep',[0.01,0.1],'String','UnName5','Style','edit','Value',[0],'VerticalAlignment','middle','Visible','on','Tag','result','Callback','')
f.visible = "on";
//////////
// Callbacks are defined as below. Please do not delete the comments as it will be used in coming version
//////////
function antena_callback(handles)
//Write your callback for antena here
endfunction
function calc_callback(handles)
//Write your callback for calc here
//fact_vel=get(handles.fv,'String'); **
//frec=get(handles.fr,'string');**
fact_vel=handles.fv.string;
frec=handles.fr.string;
equ =fact_vel * (1/frec) * 1,1 * 299792458;
//equ=handles.fv.string*(1/handles.fr.string)*1.1 * 299792458;
handles.result.string(equ);
endfunction
Agradezco cualquier ayuda