|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
RE: VB.NET Service Timer Issuethe only issue with windows 2003 / vb.net service timers. The workaround MS support suggested to keep the events firing was to periodically 'flipflop' the timers enable state somewhere in the code . Seems stupids, but keeps the timer going over extended periods or when 2 or more timers are used in the service and execute in certain ways. timer1.disable = true timer1.enable = true DeCoder Show quoteHide quote "igor" <jones_i***@yahoo.com> wrote in message news:1167168930.265904.288150@a3g2000cwd.googlegroups.com... >I have recently discovered that the system.Timers.Timer from.Net > Framework v1.1 is not reliable when used on Windows 2003 server. When > incorporated into a Windows Service, the timer_elapsed event will stop > executing after 30 to 40 days. After learning this, I found the same > issue had been documented in the the System.Threading.Timer class as > well. This limits my options for having a timer based windows service > using the .net framework. > > I can convert the project to .Net Framework 2.0, but I am unsure > whether or not this will resolve the issue. > > Any ideas would be helpful. > > Thank you. > excuse me..
should be timer1.enabled = false timer1.enabled = true Show quoteHide quote <DeCoder> wrote in message news:%23O856z4KHHA.2236@TK2MSFTNGP02.phx.gbl... >I have the same issues with windows service and timers. Your issue is not > the only issue with windows 2003 / vb.net service timers. The workaround > MS > support suggested to keep the events firing was to periodically 'flipflop' > the timers enable state somewhere in the code . Seems stupids, but keeps > the > timer going over extended periods or when 2 or more timers are used in the > service and execute in certain ways. > timer1.disable = true > timer1.enable = true > > DeCoder > > "igor" <jones_i***@yahoo.com> wrote in message > news:1167168930.265904.288150@a3g2000cwd.googlegroups.com... >>I have recently discovered that the system.Timers.Timer from.Net >> Framework v1.1 is not reliable when used on Windows 2003 server. When >> incorporated into a Windows Service, the timer_elapsed event will stop >> executing after 30 to 40 days. After learning this, I found the same >> issue had been documented in the the System.Threading.Timer class as >> well. This limits my options for having a timer based windows service >> using the .net framework. >> >> I can convert the project to .Net Framework 2.0, but I am unsure >> whether or not this will resolve the issue. >> >> Any ideas would be helpful. >> >> Thank you. >> > > > > Decoder,
Thanks for your help. I'm not sure if you saw my question on the other thread. How often do you flipflop the enabled properties? DeCoder wrote: Show quoteHide quote > excuse me.. > should be > timer1.enabled = false > timer1.enabled = true > > <DeCoder> wrote in message news:%23O856z4KHHA.2236@TK2MSFTNGP02.phx.gbl... > >I have the same issues with windows service and timers. Your issue is not > > the only issue with windows 2003 / vb.net service timers. The workaround > > MS > > support suggested to keep the events firing was to periodically 'flipflop' > > the timers enable state somewhere in the code . Seems stupids, but keeps > > the > > timer going over extended periods or when 2 or more timers are used in the > > service and execute in certain ways. > > timer1.disable = true > > timer1.enable = true > > > > DeCoder > > > > "igor" <jones_i***@yahoo.com> wrote in message > > news:1167168930.265904.288150@a3g2000cwd.googlegroups.com... > >>I have recently discovered that the system.Timers.Timer from.Net > >> Framework v1.1 is not reliable when used on Windows 2003 server. When > >> incorporated into a Windows Service, the timer_elapsed event will stop > >> executing after 30 to 40 days. After learning this, I found the same > >> issue had been documented in the the System.Threading.Timer class as > >> well. This limits my options for having a timer based windows service > >> using the .net framework. > >> > >> I can convert the project to .Net Framework 2.0, but I am unsure > >> whether or not this will resolve the issue. > >> > >> Any ideas would be helpful. > >> > >> Thank you. > >> > > > > > > > > Igor,
Take a look at my sample code in the other thread. Mike Ober. Show quoteHide quote "igor" <jones_i***@yahoo.com> wrote in message news:1167509711.480752.91780@k21g2000cwa.googlegroups.com... > Decoder, > Thanks for your help. I'm not sure if you saw my question on the > other thread. How often do you flipflop the enabled properties? > > DeCoder wrote: >> excuse me.. >> should be >> timer1.enabled = false >> timer1.enabled = true >> >> <DeCoder> wrote in message >> news:%23O856z4KHHA.2236@TK2MSFTNGP02.phx.gbl... >> >I have the same issues with windows service and timers. Your issue is >> >not >> > the only issue with windows 2003 / vb.net service timers. The >> > workaround >> > MS >> > support suggested to keep the events firing was to periodically >> > 'flipflop' >> > the timers enable state somewhere in the code . Seems stupids, but >> > keeps >> > the >> > timer going over extended periods or when 2 or more timers are used in >> > the >> > service and execute in certain ways. >> > timer1.disable = true >> > timer1.enable = true >> > >> > DeCoder >> > >> > "igor" <jones_i***@yahoo.com> wrote in message >> > news:1167168930.265904.288150@a3g2000cwd.googlegroups.com... >> >>I have recently discovered that the system.Timers.Timer from.Net >> >> Framework v1.1 is not reliable when used on Windows 2003 server. When >> >> incorporated into a Windows Service, the timer_elapsed event will stop >> >> executing after 30 to 40 days. After learning this, I found the same >> >> issue had been documented in the the System.Threading.Timer class as >> >> well. This limits my options for having a timer based windows service >> >> using the .net framework. >> >> >> >> I can convert the project to .Net Framework 2.0, but I am unsure >> >> whether or not this will resolve the issue. >> >> >> >> Any ideas would be helpful. >> >> >> >> Thank you. >> >> >> > >> > >> > >> > > |
|||||||||||||||||||||||