Path: news.mathworks.com!newsfeed-00.mathworks.com!newsfeed2.dallas1.level3.net!news.level3.com!postnews.google.com!p36g2000prn.googlegroups.com!not-for-mail
From: Nathan <ngreco32@gmail.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Gui Pushbutton default= off
Date: Mon, 20 Jul 2009 14:46:55 -0700 (PDT)
Organization: http://groups.google.com
Lines: 34
Message-ID: <14ea2dbd-e56d-4b48-8fdc-39b0060a5ee4@p36g2000prn.googlegroups.com>
References: <h42ns9$kun$1@fred.mathworks.com>
NNTP-Posting-Host: 198.206.219.33
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
X-Trace: posting.google.com 1248126416 2011 127.0.0.1 (20 Jul 2009 21:46:56 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Mon, 20 Jul 2009 21:46:56 +0000 (UTC)
Complaints-To: groups-abuse@google.com
Injection-Info: p36g2000prn.googlegroups.com; posting-host=198.206.219.33; 
	posting-account=_KeVcAoAAAB7j3xn35ujaQ0BoQhuzwJP
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1.1) 
	Gecko/20090715 Firefox/3.5.1,gzip(gfe),gzip(gfe)
X-HTTP-Via: 1.1 wwwproxy-son-ca-01.ca.sandia.gov:80 (squid/2.5.STABLE14)
Xref: news.mathworks.com comp.soft-sys.matlab:556944


On Jul 20, 2:34 pm, "ching l" <ching...@hotmail.com> wrote:
> Hello there,
>
> How do I set the pushbutton off by default?
> This is what I've tried but apparently that isn't right.
>
> -----------------------------------------------------------
> function next_Callback(hObject, eventdata, handles)
>
> handles = guidata(gcbo);
>
> set(hObject, 'enable', 'off')
>
> guidata(gcbo, handles);
>
> ------------------------------------------------------------
>
> Please advise.
>
> Thanks.

What do you mean by "off"? Do you mean disabled, or do you mean
invisible?
In either case...
Let's say your push button tag is pushbutton1

To disable it:
set(handles.pushbutton1,'Enable','off')

To make it invisible:
set(handles.pushbutton1,'Visible','off')

Either of those should work.
-Nathan