This commit is contained in:
Jonathan Jenne
2021-01-14 13:24:31 +01:00
16 changed files with 330 additions and 95 deletions

View File

@@ -43,6 +43,9 @@
<setting name="MSSQLEmailOutAccountID" serializeAs="String">
<value>1</value>
</setting>
<setting name="DEBUG" serializeAs="String">
<value>False</value>
</setting>
</DDZUGFeRDService.My.MySettings>
</applicationSettings>
<runtime>

View File

@@ -152,6 +152,15 @@ Namespace My
Return CType(Me("MSSQLEmailOutAccountID"),Integer)
End Get
End Property
<Global.System.Configuration.ApplicationScopedSettingAttribute(), _
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.Configuration.DefaultSettingValueAttribute("False")> _
Public ReadOnly Property DEBUG() As Boolean
Get
Return CType(Me("DEBUG"),Boolean)
End Get
End Property
End Class
End Namespace

View File

@@ -35,5 +35,8 @@
<Setting Name="MSSQLEmailOutAccountID" Type="System.Int32" Scope="Application">
<Value Profile="(Default)">1</Value>
</Setting>
<Setting Name="DEBUG" Type="System.Boolean" Scope="Application">
<Value Profile="(Default)">False</Value>
</Setting>
</Settings>
</SettingsFile>

View File

@@ -28,6 +28,7 @@ Public Class ThreadRunner
Public Sub New(LogConfig As LogConfig, Firebird As Firebird, Optional MSSQL As MSSQLServer = Nothing)
_logConfig = LogConfig
_logger = _logConfig.GetLogger()
_logConfig.Debug = My.Settings.DEBUG
_firebird = Firebird
_mssql = MSSQL
Try

View File

@@ -13,7 +13,7 @@ Public Class ZUGFeRDService
Protected Overrides Sub OnStart(ByVal args() As String)
_logConfig = New LogConfig(PathType.CustomPath, Path.Combine(My.Application.Info.DirectoryPath, "Log"), Nothing, "Digital Data", "DDZUGFeRDService")
_logConfig.Debug = True
_logConfig.Debug = My.Settings.DEBUG
_logger = _logConfig.GetLogger()
Try
Dim directory As New IO.DirectoryInfo(_logConfig.LogDirectory)