Thread Subject: Edit text box GUI

Subject: Edit text box GUI

From: Rob Ing

Date: 21 Mar, 2010 18:12:03

Message: 1 of 8

Hi,

I have a a edit text box on a GUI and i dont know what ive done but its magically gained up and down buttons. The up and down buttons look like they are suppose to change the value in my edit text box.

I dont want these buttons at all. Would anyone know how i could get rid of them please?

Subject: Edit text box GUI

From: Richard

Date: 21 Mar, 2010 18:20:05

Message: 2 of 8

"Rob Ing" <ringham3@hotmail.com> wrote in message <ho5nhj$sji$1@fred.mathworks.com>...
> Hi,
>
> I have a a edit text box on a GUI and i dont know what ive done but its magically gained up and down buttons. The up and down buttons look like they are suppose to change the value in my edit text box.
>
> I dont want these buttons at all. Would anyone know how i could get rid of them please?

why dont you delete the edit text box and do another one?

Subject: Edit text box GUI

From: Walter Roberson

Date: 21 Mar, 2010 18:28:06

Message: 3 of 8

Rob Ing wrote:

> I have a a edit text box on a GUI and i dont know what ive done but its
> magically gained up and down buttons. The up and down buttons look like
> they are suppose to change the value in my edit text box.

> I dont want these buttons at all. Would anyone know how i could get rid
> of them please?

Did you set the 'Maximum' parameter to something larger than 1 ? If so,
then what you are setting is probably a scroll-bar. When Maximum minus
Minimum is > 1 then the edit box accepts an indefinite number of input
lines, and so potentially needs a scroll-bar to allow the user to move
back and forth through the input.

Subject: Edit text box GUI

From: Rob Ing

Date: 21 Mar, 2010 18:29:05

Message: 4 of 8

"Richard " <richardlake@hotmail.com> wrote in message <ho5o0l$614$1@fred.mathworks.com>...
> "Rob Ing" <ringham3@hotmail.com> wrote in message <ho5nhj$sji$1@fred.mathworks.com>...
> > Hi,
> >
> > I have a a edit text box on a GUI and i dont know what ive done but its magically gained up and down buttons. The up and down buttons look like they are suppose to change the value in my edit text box.
> >
> > I dont want these buttons at all. Would anyone know how i could get rid of them please?
>
> why dont you delete the edit text box and do another one?

If i did, i would have to go to my program and change all the references to it which is a bit of a pain. Im sure there is a simple option that just needs to be changed.

Subject: Edit text box GUI

From: Rob Ing

Date: 21 Mar, 2010 18:44:03

Message: 5 of 8

Walter Roberson <roberson@hushmail.com> wrote in message <ho5ofn$mpv$1@canopus.cc.umanitoba.ca>...
> Rob Ing wrote:
>
> > I have a a edit text box on a GUI and i dont know what ive done but its
> > magically gained up and down buttons. The up and down buttons look like
> > they are suppose to change the value in my edit text box.
>
> > I dont want these buttons at all. Would anyone know how i could get rid
> > of them please?
>
> Did you set the 'Maximum' parameter to something larger than 1 ? If so,
> then what you are setting is probably a scroll-bar. When Maximum minus
> Minimum is > 1 then the edit box accepts an indefinite number of input
> lines, and so potentially needs a scroll-bar to allow the user to move
> back and forth through the input.

Indeed that is what i have done. I have set the max value to 250 and min value to 10.
I already have a slide bar that does that the job of moving through the values. I prefer the look of the slide bar to the scroll-bar that it has put on the side. Is there anyway i can over ride this?
I have set the max and min values, so it can move my slide bar to the appropriate place. So the user can input the value either by the slider or by the edit box.

Subject: Edit text box GUI

From: Walter Roberson

Date: 21 Mar, 2010 19:07:11

Message: 6 of 8

Rob Ing wrote:
> Walter Roberson <roberson@hushmail.com> wrote in message
> <ho5ofn$mpv$1@canopus.cc.umanitoba.ca>...
>> Rob Ing wrote:

>> > I have a a edit text box on a GUI and i dont know what ive done but
>> its > magically gained up and down buttons.

>> Did you set the 'Maximum' parameter to something larger than 1 ?

> Indeed that is what i have done. I have set the max value to 250 and min
> value to 10.
> I already have a slide bar that does that the job of moving through the
> values. I prefer the look of the slide bar to the scroll-bar that it has
> put on the side. Is there anyway i can over ride this?
> I have set the max and min values, so it can move my slide bar to the
> appropriate place. So the user can input the value either by the slider
> or by the edit box.

The Minimum and Maximum parameters associated with the edit box have
nothing to do with the value that appear in the edit box. Remember, an
edit box is *text* and knows nothing about how that text will be
interpreted. The Minimum and Maximum parameters associated with the edit
box have to do with the *number of lines* of text that will be accepted,
and really it is "only one line" or "an indefinite number of lines".

So to solve your problem, just don't set the Minimum and Maximum
parameters of the edit box.

Subject: Edit text box GUI

From: Rob Ing

Date: 21 Mar, 2010 19:10:05

Message: 7 of 8

"Rob Ing" <ringham3@hotmail.com> wrote in message <ho5pdj$pia$1@fred.mathworks.com>...
> Walter Roberson <roberson@hushmail.com> wrote in message <ho5ofn$mpv$1@canopus.cc.umanitoba.ca>...
> > Rob Ing wrote:
> >
> > > I have a a edit text box on a GUI and i dont know what ive done but its
> > > magically gained up and down buttons. The up and down buttons look like
> > > they are suppose to change the value in my edit text box.
> >
> > > I dont want these buttons at all. Would anyone know how i could get rid
> > > of them please?
> >
> > Did you set the 'Maximum' parameter to something larger than 1 ? If so,
> > then what you are setting is probably a scroll-bar. When Maximum minus
> > Minimum is > 1 then the edit box accepts an indefinite number of input
> > lines, and so potentially needs a scroll-bar to allow the user to move
> > back and forth through the input.
>
> Indeed that is what i have done. I have set the max value to 250 and min value to 10.
> I already have a slide bar that does that the job of moving through the values. I prefer the look of the slide bar to the scroll-bar that it has put on the side. Is there anyway i can over ride this?
> I have set the max and min values, so it can move my slide bar to the appropriate place. So the user can input the value either by the slider or by the edit box.


Problem fixed. I misunderstood the error message that matlab threw at me. It was only asking for the max and min values of the slider and not the edit box.

Subject: Edit text box GUI

From: Rob Ing

Date: 21 Mar, 2010 19:20:04

Message: 8 of 8

Walter Roberson <roberson@hushmail.com> wrote in message <ho5qov$q6q$1@canopus.cc.umanitoba.ca>...
> Rob Ing wrote:
> > Walter Roberson <roberson@hushmail.com> wrote in message
> > <ho5ofn$mpv$1@canopus.cc.umanitoba.ca>...
> >> Rob Ing wrote:
>
> >> > I have a a edit text box on a GUI and i dont know what ive done but
> >> its > magically gained up and down buttons.
>
> >> Did you set the 'Maximum' parameter to something larger than 1 ?
>
> > Indeed that is what i have done. I have set the max value to 250 and min
> > value to 10.
> > I already have a slide bar that does that the job of moving through the
> > values. I prefer the look of the slide bar to the scroll-bar that it has
> > put on the side. Is there anyway i can over ride this?
> > I have set the max and min values, so it can move my slide bar to the
> > appropriate place. So the user can input the value either by the slider
> > or by the edit box.
>
> The Minimum and Maximum parameters associated with the edit box have
> nothing to do with the value that appear in the edit box. Remember, an
> edit box is *text* and knows nothing about how that text will be
> interpreted. The Minimum and Maximum parameters associated with the edit
> box have to do with the *number of lines* of text that will be accepted,
> and really it is "only one line" or "an indefinite number of lines".
>
> So to solve your problem, just don't set the Minimum and Maximum
> parameters of the edit box.

Cheers for the solution.

I ended up solving the problem by myself and i posted my last post before seeing your last post

Tags for this Thread

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

rssFeed for this Thread

Contact us at files@mathworks.com