[REBOL] Re: Request File
From: carl:cybercraft at: 24-Jan-2004 11:51
On 21-Jan-04, Matt MacDonald wrote:
> I'm having a problem with the Request File Function. I have a timer
> as an event in the feel of a form. One of the buttons on the form
> launches the request file dialog box. The problem is that while that
> dialog box is up, my timer event is paused. I'm using the timer to
> check for inactive users, so the timer needs to be going at all
> times. Anybody have any suggestions? Here is the code for the timer:
> ; Probe time hold the timer interval, in my case it is usually 30
> seconds main-form/rate: probe-int main-form/feel: make
> main-form/feel [
> engage: func [face action event]
> [
> if (event/type = 'time)
> [probe-messages probe-type]
> ]
> ]
I'm not quite sure how your program works, but the timer in the
following keeps going while the file-requester is open...
view layout [
button "Request" [x: request-file]
time: field to-string now/time
rate 1 feel [
engage: func [face action event][
if event/type = 'time [
time/text: to-string now/time
show time
]
]
]
]
--
Carl Read