From ca423bb8617f45388acd7e0c9e41f4002c94b421 Mon Sep 17 00:00:00 2001 From: Digital Data - Marlon Schreiber Date: Thu, 5 Dec 2019 10:56:31 +0100 Subject: [PATCH] Settings DDemailService --- DDEmailService/App.config | 30 ++++ .../My Project/Settings.Designer.vb | 137 +++++++++++++----- DDEmailService/My Project/Settings.settings | 32 +++- 3 files changed, 157 insertions(+), 42 deletions(-) diff --git a/DDEmailService/App.config b/DDEmailService/App.config index 731f6de6..b4ef8fa7 100644 --- a/DDEmailService/App.config +++ b/DDEmailService/App.config @@ -1,6 +1,36 @@  + + +
+ + + + + + 172.24.12.41 + + + Data Source=172.24.12.41\Tests;Initial Catalog=DD_ECM_TEST;Persist Security Info=True;User ID=sa;Password=dd + + + Data Source=172.24.12.41\Tests;Initial Catalog=DD_ECM_TEST;Persist Security Info=True;User ID=sa;Password=dd + + + 172.24.12.41:E:\DB\Firebird\Databases\EDMI_TEMPLATE\EDMI_MASTER.FDB + + + sysdba + + + dd + + + True + + + \ No newline at end of file diff --git a/DDEmailService/My Project/Settings.Designer.vb b/DDEmailService/My Project/Settings.Designer.vb index 864ec6d4..44205a51 100644 --- a/DDEmailService/My Project/Settings.Designer.vb +++ b/DDEmailService/My Project/Settings.Designer.vb @@ -1,10 +1,10 @@ '------------------------------------------------------------------------------ ' -' This code was generated by a tool. -' Runtime Version:4.0.30319.42000 +' Dieser Code wurde von einem Tool generiert. +' Laufzeitversion:4.0.30319.42000 ' -' Changes to this file may cause incorrect behavior and will be lost if -' the code is regenerated. +' Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn +' der Code erneut generiert wird. ' '------------------------------------------------------------------------------ @@ -13,57 +13,122 @@ Option Explicit On Namespace My - - _ + + _ Partial Friend NotInheritable Class MySettings Inherits Global.System.Configuration.ApplicationSettingsBase - - Private Shared defaultInstance As MySettings = CType(Global.System.Configuration.ApplicationSettingsBase.Synchronized(New MySettings), MySettings) - -#Region "My.Settings Auto-Save Functionality" + + Private Shared defaultInstance As MySettings = CType(Global.System.Configuration.ApplicationSettingsBase.Synchronized(New MySettings()),MySettings) + +#Region "Automatische My.Settings-Speicherfunktion" #If _MyType = "WindowsForms" Then - Private Shared addedHandler As Boolean + Private Shared addedHandler As Boolean - Private Shared addedHandlerLockObject As New Object + Private Shared addedHandlerLockObject As New Object - _ - Private Shared Sub AutoSaveSettings(ByVal sender As Global.System.Object, ByVal e As Global.System.EventArgs) - If My.Application.SaveMySettingsOnExit Then - My.Settings.Save() - End If - End Sub + _ + Private Shared Sub AutoSaveSettings(sender As Global.System.Object, e As Global.System.EventArgs) + If My.Application.SaveMySettingsOnExit Then + My.Settings.Save() + End If + End Sub #End If #End Region - + Public Shared ReadOnly Property [Default]() As MySettings Get - + #If _MyType = "WindowsForms" Then - If Not addedHandler Then - SyncLock addedHandlerLockObject - If Not addedHandler Then - AddHandler My.Application.Shutdown, AddressOf AutoSaveSettings - addedHandler = True - End If - End SyncLock - End If + If Not addedHandler Then + SyncLock addedHandlerLockObject + If Not addedHandler Then + AddHandler My.Application.Shutdown, AddressOf AutoSaveSettings + addedHandler = True + End If + End SyncLock + End If #End If Return defaultInstance End Get End Property + + _ + Public ReadOnly Property FB_ConnString() As String + Get + Return CType(Me("FB_ConnString"),String) + End Get + End Property + + _ + Public ReadOnly Property SQLSERVER_CS() As String + Get + Return CType(Me("SQLSERVER_CS"),String) + End Get + End Property + + _ + Public ReadOnly Property SQLSERVER_CS_TEST() As String + Get + Return CType(Me("SQLSERVER_CS_TEST"),String) + End Get + End Property + + _ + Public ReadOnly Property FB_DATABASE() As String + Get + Return CType(Me("FB_DATABASE"),String) + End Get + End Property + + _ + Public ReadOnly Property FB_USER() As String + Get + Return CType(Me("FB_USER"),String) + End Get + End Property + + _ + Public ReadOnly Property FB_PW() As String + Get + Return CType(Me("FB_PW"),String) + End Get + End Property + + _ + Public ReadOnly Property DEBUG() As Boolean + Get + Return CType(Me("DEBUG"),Boolean) + End Get + End Property End Class End Namespace Namespace My - - _ + + _ Friend Module MySettingsProperty - - _ + + _ Friend ReadOnly Property Settings() As Global.DDEmailService.My.MySettings Get Return Global.DDEmailService.My.MySettings.Default diff --git a/DDEmailService/My Project/Settings.settings b/DDEmailService/My Project/Settings.settings index 85b890b3..c0ddb929 100644 --- a/DDEmailService/My Project/Settings.settings +++ b/DDEmailService/My Project/Settings.settings @@ -1,7 +1,27 @@  - - - - - - + + + + + 172.24.12.41 + + + Data Source=172.24.12.41\Tests;Initial Catalog=DD_ECM_TEST;Persist Security Info=True;User ID=sa;Password=dd + + + Data Source=172.24.12.41\Tests;Initial Catalog=DD_ECM_TEST;Persist Security Info=True;User ID=sa;Password=dd + + + 172.24.12.41:E:\DB\Firebird\Databases\EDMI_TEMPLATE\EDMI_MASTER.FDB + + + sysdba + + + dd + + + True + + + \ No newline at end of file