To make the slider update when the editbox is updated, put the update code in the editbox callback
function myEditBox_Callback(hObject,eventdata,handles)
val = str2double(get(hObject,'String'));
set(handles.slider1,'Value',val);
guidata(hObject,handles)
And then, in the slider's callback:
function slider1_Callback(hObject,eventdata,handles)
val = get(hObject,'Value');
set(handles.myEditBox,'String',num2str(val));
guidata(hObject,handles)
Best Answer