My Application Log

Solarion

Honorary Master
Joined
Nov 14, 2012
Messages
21,886
Code:
Public Sub sendEMail()
Try

'Do some stuff in here

Catch ex As Exception
My.Application.Log.WriteException(ex, _
TraceEventType.Error, _
"Exception with argument " & ex.Message & ".")
Finally
MessageBox.Show("Email successfully sent")
End Try

I have one question. Where do I find this log?
 
Last edited:

Ianvn

Well-Known Member
Joined
Jan 15, 2008
Messages
209
You can use
My.Application.Log.DefaultFileLogWriter.FullLogFileName
to get the filepath.


My.Application.Log.DefaultFileLogWriter.BaseFileName can be used to set the file name.

My.Application.Log.DefaultFileLogWriter.CustomLocation can be used to set the location
 
Top