From: Jan Simon on
Dear lesego!

> Thanks pointing that out Jan. in fact, i copied and pasted the script i was still working on. the original one had 'clear' at the top and 'clc' at the very bottom. sorry for the confusion.

Ok. So you could simply omit the trailing CLC.

Another idea would be to create a TIMER object, which calls CLC once only after a specified number of seconds. But this might confuse a user seriously!

Kind regards, Jan
From: Steven Lord on

"lesego Nnyaya" <nnyaya(a)hotmail.com> wrote in message
news:hrpq9r$91n$1(a)fred.mathworks.com...
> "checker i" <checker.im(a)gmail.com> wrote in message
> <hrpnbn$nng$1(a)fred.mathworks.com>...
>> "lesego Nnyaya" <nnyaya(a)hotmail.com> wrote in message
>> <hrpmu0$pdh$1(a)fred.mathworks.com>...
>
>> have you tried 'pause' command?
>
> thanks a lot for your quick response. 'pause' indeed is one of the options
> i could use, but like the name says it pauses execution of a script or
> function until the user intervenes by hitting the enter button. in my
> case, i do not want the user to do that, because then i'd have to let the
> user know that he has to press that key. i'm just looking for a way to do
> the countdown, say from 3s to 0s, until 'clear' command is executed.

One of the ways you can use PAUSE does in fact pause until the user strikes
a key. But that's not the only way you can use PAUSE. Look at the first
syntax given in "help pause".

--
Steve Lord
slord(a)mathworks.com
comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ


From: lesego Nnyaya on
"Steven Lord" <slord(a)mathworks.com> wrote in message <hrpugs$obb$1(a)fred.mathworks.com>...
>
> "lesego Nnyaya" <nnyaya(a)hotmail.com> wrote in message
> news:hrpq9r$91n$1(a)fred.mathworks.com...
> > "checker i" <checker.im(a)gmail.com> wrote in message
> > <hrpnbn$nng$1(a)fred.mathworks.com>...
> >> "lesego Nnyaya" <nnyaya(a)hotmail.com> wrote in message
> >> <hrpmu0$pdh$1(a)fred.mathworks.com>...
> >
> >> have you tried 'pause' command?
> >
> > thanks a lot for your quick response. 'pause' indeed is one of the options
> > i could use, but like the name says it pauses execution of a script or
> > function until the user intervenes by hitting the enter button. in my
> > case, i do not want the user to do that, because then i'd have to let the
> > user know that he has to press that key. i'm just looking for a way to do
> > the countdown, say from 3s to 0s, until 'clear' command is executed.
>
> One of the ways you can use PAUSE does in fact pause until the user strikes
> a key. But that's not the only way you can use PAUSE. Look at the first
> syntax given in "help pause".
>
> --
> Steve Lord
> slord(a)mathworks.com
> comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ
>
Thanks Steve, that solves my problem.

Regards,
Lesego.
First  |  Prev  | 
Pages: 1 2
Prev: integration
Next: newff neural network