local timer = createTimer(nil, false) timer.OnTimer = function () if(getMainForm().Visible) then local date = os.date("*t") if(date.day == 1 and date.month == 4) then getMainForm().btnNextScan.Visible = false --destroy() end timer.destroy() end end timer.Interval = 1000 timer.Enabled = true