|
"wma " <wma@wma.test> wrote in message <hksbe1$5d2$1@fred.mathworks.com>...
> > 1. Use the UIInspect utility to understand which methods and properties are available on your object: http://www.mathworks.com/matlabcentral/fileexchange/17935-uiinspect-display-methodspropertiescallbacks-of-an-object . In your specific case, there are separate properties (and accessor methods) for hiding/showing and for enabling/disabling.
> > 2. Dynamic menu items were explained here: http://undocumentedmatlab.com/blog/setting-listbox-mouse-actions/
> > 3. Rich-text in Matlab text-areas (editboxes) was explained here: http://undocumentedmatlab.com/blog/rich-matlab-editbox-contents/
> >
> > Yair Altman
> > http://UndocumentedMatlab.com
>
> Thank you for your answer. thank you for this very interesting tool
>
> I'm still stuck here:
>
> I created an object like this:
> introtext=uicomponent('style','JLabel','Text',output,'Position',[10,610,420],'Tag','introtext');
>
> at a later point i want to delete or "unvisible" it, how do i manage to delete this object?
>
> set(handles.introtext,'Visible','off') does not work.
set(introtext,'visible','off') works for me. In your case, handles.introtext may be an empty or invalid handle - set a breakpoint and check.
To completely delete the label, simply do delete(introtext), just like for any other Matlab control. As before, you need a valid handle or else it will not work.
Yair Altman
http://UndocumentedMatlab.com
|