In addition to Sergey's advise, here is a simple model with the timer object in a 'user' form
ft=CREATEOBJECT('form')
ft.Show
ft.AddObject('text1','textbox')
ft.text1.Visible=.t.
ft.text1.setfocus
ft.addobject('T1','clsTimer')
DEFINE CLASS clsTimer as Timer
interval=3000
PROCEDURE Timer
IF thisform.backcolor=RGB(255,0,0)
thisform.backcolor=RGB(0,0,255)
ELSE
thisform.backcolor=RGB(255,0,0)
ENDIF
this.Interval=3000
ENDPROC
A timer cannot be embedded in a COM. But you might be able to mimic the desired behavior with an "invisible" form providing iot opens in the same space your application does.
>If I have some logic in a timer control and enable the timer in my code, can I still interact with the rest of the user interface and have the logic in the timer run at the same time?
>
>Jim
>
>>>IS it possible in any VFP version to program using threads? If so, can someone please point me to an article?
>>
>>No VFP, doesn't support thread programming. See if
Multi-threaded VFP application File #
9838 may work for you.
Imagination is more important than knowledge