Hi Alessandro,
Here's your example in standard VID. Be sure to use "view/new" so that
the view
function returns immediately. That way, you can put code to be
evaluated after
the gui layout is created:
rebol []
view/new layout [
text "PROGRESS"
pro: progress
]
repeat counter 10 [
do [
incr: .0
repeat newCounter 11 [
pro/data: incr
show pro
incr: incr + 0.1
wait .1
]
]
]
unview
To make a layout created with view/new event driven, use "do-events". For
example:
view layout [pro: progress]
is the same as:
view/new layout [pro: progress]
do-events
Hope that helps!
Quoting Alessandro Manotti <[EMAIL PROTECTED]>:
>
> Dear all, I'm a newbe in Rebol.
>
> I'm creating a Rebol application, and I need to display a progress bar
> (I'm using RebGUI, but I think the concept is the same using classic
> view) without user interaction.
> I hope the following example will better explain what I need (it is
> not the real code I'm programming, but an easy code I create just
> represent my real problem):
>
> repeat counter 10 [
>
> display compose/deep/only "PROGRESS" [
> pro: progress
>
> do [
> incr: 0
> repeat newCounter 10 [
> pro/data: incr
> incr: incr + 0.1
> ]
> ]
>
> unview
> ]
>
>
> Well, the problem is I don't see any progress in the bar, since the
> form is not shown until the do [ ... ] loop does not finish!
>
> Can you help me?
>
> Thank you!
>
> --Alessandro
> --
> To unsubscribe from the list, just send an email to
> lists at rebol.com with unsubscribe as the subject.
>
>
--
To unsubscribe from the list, just send an email to
lists at rebol.com with unsubscribe as the subject.