Click here to Skip to main content
16,014,860 members
Home / Discussions / Visual Basic
   

Visual Basic

 
QuestionSniffing detection on ethernet Pin
asim araeen19-Sep-08 17:14
asim araeen19-Sep-08 17:14 
AnswerRe: Sniffing detection on ethernet Pin
jzonthemtn20-Sep-08 9:12
jzonthemtn20-Sep-08 9:12 
AnswerRe: Sniffing detection on ethernet Pin
Paul Conrad20-Sep-08 10:59
professionalPaul Conrad20-Sep-08 10:59 
QuestionPassword and registry Pin
afridy19-Sep-08 14:14
afridy19-Sep-08 14:14 
AnswerRe: Password and registry Pin
Rupesh Kumar Swami19-Sep-08 20:25
Rupesh Kumar Swami19-Sep-08 20:25 
GeneralRe: Password and registry Pin
afridy19-Sep-08 20:30
afridy19-Sep-08 20:30 
GeneralRe: Password and registry Pin
Rupesh Kumar Swami19-Sep-08 20:48
Rupesh Kumar Swami19-Sep-08 20:48 
QuestionWindow Service doesn't run continously using vb 2005 Pin
CARisk319-Sep-08 11:20
CARisk319-Sep-08 11:20 
I'm not sure this is the correct place to post but since I wrote the code in vb I figured I would start here. I have a service that I created that writes to a text file, but it only writes 16 times and then stops. I have not asked it to stop it just does it on it's own. I am using this for testing because I have a bigger project that I need to create as a Window service and the timer wasn't working in it. So I created this small testing project and still can't get the timer to work correctly. Could some one please give me some clues as to what might be wrong with the code? I copied below what I am using.

Public Class AuthorLog

Protected Overrides Sub OnStart(ByVal args() As String)
' Add code here to start your service. This method should set things
' in motion so your service can do its work.

Const iTIME_INTERVAL As Integer = 15000 ' 15 seconds.
Dim oTimer As System.Threading.Timer
Dim strline = vbCrLf

System.IO.File.AppendAllText("C:\AuthorLog.txt", "AuthorLogService has been started at " & Now.ToString() & vbCrLf)


Dim tDelegate As Threading.TimerCallback = AddressOf EventAction
oTimer = New System.Threading.Timer(tDelegate, Me, 0, iTIME_INTERVAL)


End Sub

Protected Overrides Sub OnStop()
' Add code here to perform any tear-down necessary to stop your service.
End Sub

Public Sub EventAction(ByVal sender As Object)

System.IO.File.AppendAllText("C:\AuthorLog.txt", "AuthorLogService fires EventAction at " & Now.ToString() & vbCrLf)

End Sub


End Class

Thanks for your assistance in advance.

Carolyn

If you can’t have fun at work, then why go to work?

AnswerRe: Window Service doesn't run continously using vb 2005 Pin
Dave Kreskowiak20-Sep-08 7:57
mveDave Kreskowiak20-Sep-08 7:57 
GeneralRe: Window Service doesn't run continously using vb 2005 Pin
CARisk38-Oct-08 6:24
CARisk38-Oct-08 6:24 
GeneralRe: Window Service doesn't run continously using vb 2005 Pin
Dave Kreskowiak8-Oct-08 12:22
mveDave Kreskowiak8-Oct-08 12:22 
GeneralRe: Window Service doesn't run continously using vb 2005 Pin
CARisk38-Oct-08 12:37
CARisk38-Oct-08 12:37 
GeneralRe: Window Service doesn't run continously using vb 2005 Pin
Dave Kreskowiak8-Oct-08 15:12
mveDave Kreskowiak8-Oct-08 15:12 
GeneralRe: Window Service doesn't run continously using vb 2005 Pin
CARisk39-Oct-08 4:06
CARisk39-Oct-08 4:06 
QuestionVisual Studio 2008 Web Deployment - error writing file Pin
cab319-Sep-08 8:48
cab319-Sep-08 8:48 
AnswerRe: Visual Studio 2008 Web Deployment - error writing file Pin
Dave Kreskowiak20-Sep-08 7:54
mveDave Kreskowiak20-Sep-08 7:54 
GeneralRe: Visual Studio 2008 Web Deployment - error writing file Pin
cab322-Sep-08 13:04
cab322-Sep-08 13:04 
QuestionVB 6 .0 setup merage crystal report 8.0 Pin
Bhim Prakash Singh19-Sep-08 5:52
Bhim Prakash Singh19-Sep-08 5:52 
AnswerRe: VB 6 .0 setup merage crystal report 8.0 Pin
Dave Kreskowiak19-Sep-08 7:50
mveDave Kreskowiak19-Sep-08 7:50 
AnswerRe: VB 6 .0 setup merage crystal report 8.0 Pin
Ashfield19-Sep-08 8:59
Ashfield19-Sep-08 8:59 
AnswerRe: VB 6 .0 setup merage crystal report 8.0 Pin
Paul Conrad19-Sep-08 10:19
professionalPaul Conrad19-Sep-08 10:19 
QuestionGetting Company Name in VB.net Pin
Gagan.2019-Sep-08 5:44
Gagan.2019-Sep-08 5:44 
AnswerRe: Getting Company Name in VB.net Pin
jzonthemtn19-Sep-08 7:07
jzonthemtn19-Sep-08 7:07 
GeneralRe: Getting Company Name in VB.net Pin
Gagan.2020-Sep-08 4:19
Gagan.2020-Sep-08 4:19 
QuestionVB.net Graphics Pin
Gagan.2019-Sep-08 5:41
Gagan.2019-Sep-08 5:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.