I have following matlab GUI code.
clear all;
clc;
win = figure('units','points',...
'position',[200 250 500 400],...
'color',[.8 .8 .8],...
'menubar','none',...
'resize','off',...
'numbertitle','off',...
'name','test window');
menu = uimenu('parent',win,...
'Label','File');
submenu1 = uimenu('parent',menu,...
'Label','Open');
submenu2 = uimenu('parent',menu,...
'Label','Exit',...
'Callback','close');
frame1 = uicontrol('parent',win,...
'units','points',...
'position',[30 170 200 200],...
'backgroundcolor',[.9 .9 .9],...
'style','Frame');
recButton = uicontrol('parent',win,...
'units','points',...
'position',[90 130 70 30],...
'style','pushbutton',...
'string','Button');
What I want to do is load an image with Open submenu (submenu1) and then display it inside frame1. I want recButton is disabled by default. After the image is loaded recButton becomes enabled. Can you help me with the code?