Windows Service

  • Thread starter Thread starter Boris Bulit
  • Start date Start date
B

Boris Bulit

I try to create my first windows service in VB.NET following this article
http://abstractvb.com/code.asp?A=1082,
I follow step by step but it doesn´t , the event tick of the timer never
run.


Someone know something about this or have a simple sample code


Thanks


Boris
 
Hi Boris,

I'm going to take a shot in the dark and guess that your problem is caused
by the Timer control that you are using. There are actually several
different timers that you can use, and the System.Windows.Forms.Timer (I'm
guessing this is the one you're using) will not work with WindowsServices
(to the best of my knowledge).

You will want to use something like the System.Timers.Timer. You can find
this control under the Components Tab in the Designer Toolbox (you should
see Data, Components, Windows Forms, and General).

Just drag and drop the Components>Timer onto your Service in the designer
and follow the rest of the tutorials instructions "as is".

I hope that helps!
 
Back
Top