Page 1 of 1

The timer interval is changed after disabling/enabling

Posted: Thu Nov 19, 2009 9:56 am
by gfilatov
Hi Roberto,

There is a small issue with a Timer interval management.
The timer interval is changed after disabling and then enabling this timer. :o

Please take a look for the following sample: :arrow:

Code: Select all

#include "minigui.ch"

Function Main

	DEFINE WINDOW Form_1 ;
		AT 0,0 ;
		WIDTH 400 ;
		HEIGHT 400 ;
		TITLE 'Timer Test' ;
		MAIN 

		DEFINE TIMER Timer_1 ;
		INTERVAL 10000 ;
		ACTION TimerTest() 

	END WINDOW

	Form_1.Timer_1.Value := 2000

	ACTIVATE WINDOW Form_1

Return Nil

Procedure TimerTest()

*	If time() == "11:00:00"
*		RELEASE WINDOW MAIN
*	EndIf

        // here Timer_1 inverval = 2 sec
	Form_1.Timer_1.Enabled := .F.
	MsgInfo ('Hey!')
	Form_1.Timer_1.Enabled := .T.
        // here Timer_1 inverval = 10 sec

Return

Re: The timer interval is changed after disabling/enabling

Posted: Thu Nov 19, 2009 1:19 pm
by Roberto Lopez
gfilatov wrote:Hi Roberto,

There is a small issue with a Timer interval management.
The timer interval is changed after disabling and then enabling this timer. :o
Thanks for the report. I'll check it ASAP.