From 5177e99ded94bf678ac04359d71e57139d25574d Mon Sep 17 00:00:00 2001 From: Jonathan Jenne Date: Tue, 16 Apr 2019 16:26:31 +0200 Subject: [PATCH] Add Test Mode --- app/DD_PM_WINDREAM/ClassConfig.vb | 1 + app/DD_PM_WINDREAM/ClassInit.vb | 3 +- app/DD_PM_WINDREAM/ModuleMySettings.vb | 1 + app/DD_PM_WINDREAM/frmKonfig.Designer.vb | 23 +- app/DD_PM_WINDREAM/frmKonfig.resx | 1593 +++++++++++++--------- app/DD_PM_WINDREAM/frmKonfig.vb | 46 +- 6 files changed, 1033 insertions(+), 634 deletions(-) diff --git a/app/DD_PM_WINDREAM/ClassConfig.vb b/app/DD_PM_WINDREAM/ClassConfig.vb index dc09ab3..b767df3 100644 --- a/app/DD_PM_WINDREAM/ClassConfig.vb +++ b/app/DD_PM_WINDREAM/ClassConfig.vb @@ -6,6 +6,7 @@ Public Class ClassConfig Public Property ConnectionString As String = "" Public Property ConnectionStringTest As String = "" + Public Property TestMode As Boolean = False ' PDF Viewer Settings Public Property UniversalViewerPath As String = "" diff --git a/app/DD_PM_WINDREAM/ClassInit.vb b/app/DD_PM_WINDREAM/ClassInit.vb index 53b5887..f3ff9de 100644 --- a/app/DD_PM_WINDREAM/ClassInit.vb +++ b/app/DD_PM_WINDREAM/ClassInit.vb @@ -24,7 +24,7 @@ Public Class ClassInit CONFIG = New ConfigManager(Of ClassConfig)(LOGCONFIG, Application.UserAppDataPath, Application.CommonAppDataPath) LOGGER.Info("Config loaded") - If CONFIG.Config.ConnectionStringTest <> String.Empty Then + If CONFIG.Config.ConnectionStringTest <> String.Empty And CONFIG.Config.TestMode = True Then LOGGER.Debug("Test Connection String loaded") CONNECTION_STRING = DecryptConnectionString(CONFIG.Config.ConnectionStringTest) Else @@ -46,6 +46,7 @@ Public Class ClassInit LOG_ERRORS_ONLY = CONFIG.Config.LogErrorsOnly LOGCONFIG.Debug = Not LOG_ERRORS_ONLY + TEST_MODE = CONFIG.Config.TestMode 'Settings_Load() End Sub diff --git a/app/DD_PM_WINDREAM/ModuleMySettings.vb b/app/DD_PM_WINDREAM/ModuleMySettings.vb index 912141c..fdd1270 100644 --- a/app/DD_PM_WINDREAM/ModuleMySettings.vb +++ b/app/DD_PM_WINDREAM/ModuleMySettings.vb @@ -1,6 +1,7 @@ Module ModuleMySettings ' Connection String Public CONNECTION_STRING As String = "" + Public TEST_MODE As String = False ' Debug Settings Public LOG_ERRORS_ONLY As Boolean = True diff --git a/app/DD_PM_WINDREAM/frmKonfig.Designer.vb b/app/DD_PM_WINDREAM/frmKonfig.Designer.vb index eabf5ee..cf35e60 100644 --- a/app/DD_PM_WINDREAM/frmKonfig.Designer.vb +++ b/app/DD_PM_WINDREAM/frmKonfig.Designer.vb @@ -22,7 +22,6 @@ Partial Class frmKonfig 'Das Bearbeiten mit dem Code-Editor ist nicht möglich. _ Private Sub InitializeComponent() - Me.components = New System.ComponentModel.Container() Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmKonfig)) Me.btnuniversalview = New System.Windows.Forms.Button() Me.Label13 = New System.Windows.Forms.Label() @@ -69,9 +68,11 @@ Partial Class frmKonfig Me.Button1 = New System.Windows.Forms.Button() Me.btnLogMail = New System.Windows.Forms.Button() Me.DD_DMSLiteDataSet = New DD_PM_WINDREAM.DD_DMSLiteDataSet() - Me.TBPM_KONFIGURATIONBindingSource = New System.Windows.Forms.BindingSource(Me.components) + Me.TBPM_KONFIGURATIONBindingSource = New System.Windows.Forms.BindingSource() Me.TBPM_KONFIGURATIONTableAdapter = New DD_PM_WINDREAM.DD_DMSLiteDataSetTableAdapters.TBPM_KONFIGURATIONTableAdapter() Me.TableAdapterManager = New DD_PM_WINDREAM.DD_DMSLiteDataSetTableAdapters.TableAdapterManager() + Me.RadioDefaultConnection = New System.Windows.Forms.RadioButton() + Me.RadioAlternativeConnection = New System.Windows.Forms.RadioButton() Me.TabControl1.SuspendLayout() Me.TabPage1.SuspendLayout() Me.GroupBox1.SuspendLayout() @@ -221,6 +222,8 @@ Partial Class frmKonfig ' 'TabPage2 ' + Me.TabPage2.Controls.Add(Me.RadioAlternativeConnection) + Me.TabPage2.Controls.Add(Me.RadioDefaultConnection) Me.TabPage2.Controls.Add(Me.chkbxUserAut) Me.TabPage2.Controls.Add(Me.Label5) Me.TabPage2.Controls.Add(Me.cmbDatenbank) @@ -413,6 +416,20 @@ Partial Class frmKonfig Me.TableAdapterManager.TBPM_TYPETableAdapter = Nothing Me.TableAdapterManager.UpdateOrder = DD_PM_WINDREAM.DD_DMSLiteDataSetTableAdapters.TableAdapterManager.UpdateOrderOption.InsertUpdateDelete ' + 'RadioDefaultConnection + ' + resources.ApplyResources(Me.RadioDefaultConnection, "RadioDefaultConnection") + Me.RadioDefaultConnection.Checked = True + Me.RadioDefaultConnection.Name = "RadioDefaultConnection" + Me.RadioDefaultConnection.TabStop = True + Me.RadioDefaultConnection.UseVisualStyleBackColor = True + ' + 'RadioAlternativeConnection + ' + resources.ApplyResources(Me.RadioAlternativeConnection, "RadioAlternativeConnection") + Me.RadioAlternativeConnection.Name = "RadioAlternativeConnection" + Me.RadioAlternativeConnection.UseVisualStyleBackColor = True + ' 'frmKonfig ' resources.ApplyResources(Me, "$this") @@ -482,4 +499,6 @@ Partial Class frmKonfig Friend WithEvents Label7 As System.Windows.Forms.Label Friend WithEvents txtIntervall As System.Windows.Forms.TextBox Friend WithEvents Label6 As System.Windows.Forms.Label + Friend WithEvents RadioAlternativeConnection As RadioButton + Friend WithEvents RadioDefaultConnection As RadioButton End Class diff --git a/app/DD_PM_WINDREAM/frmKonfig.resx b/app/DD_PM_WINDREAM/frmKonfig.resx index 5f71906..632bdf5 100644 --- a/app/DD_PM_WINDREAM/frmKonfig.resx +++ b/app/DD_PM_WINDREAM/frmKonfig.resx @@ -278,957 +278,1257 @@ 5 - - True - - - Segoe UI, 9.75pt, style=Bold + + GroupBox1 - - 7, 30 + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 185, 21 + + TabPage1 - + 0 - - Internen Viewer benutzen + + txtUniversalViewer - - rbPDF_internal + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + TabPage1 - - GroupBox1 + + 2 - - 0 + + Verdana, 9.75pt - - True + + 4, 26 - - Segoe UI, 9.75pt, style=Bold + + + 3, 3, 3, 3 - - 6, 203 + + 832, 318 - - 186, 21 + + 0 - - 8 + + Darstellung Dateien: - - Standard-(System) Viewer + + TabPage1 - - rbSystem + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + TabControl1 - - GroupBox1 + + 0 - - 1 + + RadioAlternativeConnection - - 265, 30 + + System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 228, 23 + + TabPage2 - - 2 + + 0 - - Keinen separaten pdf-Viewer + + RadioDefaultConnection - - btnno_pdf_viewer + + System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + TabPage2 - - GroupBox1 + + 1 - - 2 + + chkbxUserAut - - True + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - Segoe UI, 9.75pt, style=Bold + + TabPage2 - - 7, 131 + + 2 - - 284, 21 + + Label5 - - 5 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - Sumatra zur Darstellung für pdf-benutzen + + TabPage2 - - rbSumatra + + 3 - - System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + cmbDatenbank - - GroupBox1 + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 3 + + TabPage2 - - True + + 4 - - Segoe UI, 9.75pt, style=Bold + + Label4 - - 6, 59 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 318, 21 + + TabPage2 - - 1 + + 5 - - PDF-XChange zur Darstellung für pdf-benutzen + + Label1 - - rbPDFX_Change + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + TabPage2 - - GroupBox1 + + 6 - - 4 + + Label2 - - 604, 174 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 32, 23 + + TabPage2 - + 7 - - ... + + Label3 - - btnSumatra + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + TabPage2 - - GroupBox1 + + 8 - - 6 + + txtUser - - 25, 102 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 573, 23 + + TabPage2 - - 3 + + 9 - - txtpdfxchange + + txtPasswort - + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - GroupBox1 + + TabPage2 - - 7 + + 10 - - 25, 174 + + BtnConnect - - 573, 23 + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 6 + + TabPage2 - - txtSumatra + + 11 - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + txtActualConnection - - GroupBox1 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 8 + + TabPage2 - - True + + 12 - - 22, 155 + + txtServer - - 183, 16 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 21 + + TabPage2 - - Installationspfad Sumatra: + + 13 - - lblSumatra + + 4, 26 - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 3, 3, 3, 3 - - GroupBox1 + + 832, 318 - - 10 + + 1 - - 10, 77 + + Datenbankverbindung: - - 659, 234 + + TabPage2 - - 25 + + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - PDF-Viewer (optional) + + TabControl1 - - GroupBox1 + + 1 - - System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + True - - TabPage1 + + 52, 165 - + + 55, 17 + + + 45 + + + Minuten + + + Label7 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + TabPage3 + + 0 - - 10, 22 + + 8, 162 - - 573, 23 + + 38, 25 - - 13 + + 44 - - txtUniversalViewer + + Center - + + txtIntervall + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - TabPage1 + + TabPage3 - + + 1 + + + True + + + 5, 142 + + + 159, 17 + + + 43 + + + Intervall Popup-Reminder: + + + Label6 + + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + TabPage3 + + 2 - - Verdana, 9.75pt + + MiddleLeft - + + 8, 99 + + + 219, 28 + + + 42 + + + Öffne Log-Verzeichnis + + + btnopenlog + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + TabPage3 + + + 3 + + + True + + + 506, 28 + + + 117, 21 + + + 41 + + + Log Errors only + + + chkLogErrorsOnly + + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + TabPage3 + + + 4 + + + 8, 64 + + + 219, 29 + + + 40 + + + Open Appdata-Folder + + + Button3 + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + TabPage3 + + + 5 + + + True + + + 233, 29 + + + 166, 17 + + + 39 + + + Support-Portal Digital Data + + + LinkLabel1 + + + System.Windows.Forms.LinkLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + TabPage3 + + + 6 + + + 506, 105 + + + 219, 28 + + + 38 + + + List all processes + + + Button2 + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + TabPage3 + + + 7 + + + 506, 71 + + + 219, 29 + + + 37 + + + Get Culture Info + + + Button1 + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + TabPage3 + + + 8 + + + MiddleLeft + + + 8, 17 + + + 219, 41 + + + 0 + + + Log/Support Mail erzeugen + + + MiddleRight + + + btnLogMail + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + TabPage3 + + + 9 + + 4, 26 - - + 3, 3, 3, 3 - + 832, 318 - - 0 + + 2 - - Darstellung Dateien: + + Weiteres - - TabPage1 + + TabPage3 - + System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - + TabControl1 - - 0 + + 2 - - True + + Fill - - 510, 32 + + 0, 0 - - 182, 21 + + 840, 348 - - 35 + + 21 - - Windows-Authentifizierung + + TabControl1 - - chkbxUserAut + + System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + $this - - TabPage2 + + 0 - + + rbPDF_internal + + + System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + GroupBox1 + + 0 - - True + + rbSystem - - 5, 111 + + System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 164, 17 + + GroupBox1 - - 34 + + 1 - - Aktueller ConnectionString: + + btnno_pdf_viewer - - Label5 + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - + + GroupBox1 + + + 2 + + + rbSumatra + + + System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + GroupBox1 + + + 3 + + + rbPDFX_Change + + + System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + GroupBox1 + + + 4 + + + btnSumatra + + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + GroupBox1 + + + 6 + + + txtpdfxchange + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + GroupBox1 + + + 7 + + + txtSumatra + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + GroupBox1 + + + 8 + + + lblSumatra + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - TabPage2 + + GroupBox1 - - 1 + + 10 + + + 10, 77 - - 8, 78 + + 659, 234 - - 252, 25 + + 25 - - 27 + + PDF-Viewer (optional) - - cmbDatenbank + + GroupBox1 - - System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.GroupBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - TabPage2 + + TabPage1 - - 2 + + 0 - + True - - 5, 58 + + Segoe UI, 9.75pt, style=Bold - - 73, 17 + + 7, 30 - - 32 + + 185, 21 - - Datenbank: + + 0 - - Label4 + + Internen Viewer benutzen - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + rbPDF_internal - - TabPage2 + + System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 3 + + GroupBox1 - + + 0 + + True - - 5, 10 + + Segoe UI, 9.75pt, style=Bold - - 88, 17 + + 6, 203 - - 29 + + 186, 21 - - Server-Name: + + 8 - - Label1 + + Standard-(System) Viewer - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + rbSystem - - TabPage2 + + System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 4 + + GroupBox1 - - True + + 1 - - 299, 10 + + 265, 30 - - 93, 17 + + 228, 23 - - 30 + + 2 - - Benutzername: + + Keinen separaten pdf-Viewer - - Label2 + + btnno_pdf_viewer - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - TabPage2 + + GroupBox1 - - 5 + + 2 - + True - - 423, 10 + + Segoe UI, 9.75pt, style=Bold - - 63, 17 + + 7, 131 - - 31 + + 284, 21 - - Passwort: + + 5 - - Label3 + + Sumatra zur Darstellung für pdf-benutzen - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + rbSumatra - - TabPage2 + + System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 6 + + GroupBox1 - - 302, 30 + + 3 - - 118, 25 + + True - - 25 + + Segoe UI, 9.75pt, style=Bold - - txtUser + + 6, 59 - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 318, 21 - - TabPage2 + + 1 - - 7 + + PDF-XChange zur Darstellung für pdf-benutzen - - 426, 30 + + rbPDFX_Change - - 64, 25 + + System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 26 + + GroupBox1 - - txtPasswort + + 4 - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 604, 174 - - TabPage2 + + 32, 23 - - 8 + + 7 - - MiddleLeft + + ... - - 302, 78 + + btnSumatra - - 253, 25 + + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 28 + + GroupBox1 - - Verbindung zur Datenbank herstellen + + 6 - - MiddleRight + + 25, 102 - - BtnConnect + + 573, 23 - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + 3 - - TabPage2 + + txtpdfxchange + + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 9 + + GroupBox1 - - Top, Left, Right + + 7 - - 8, 131 + + 25, 174 - - 744, 25 + + 573, 23 - - 33 + + 6 - - txtActualConnection + + txtSumatra - + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - TabPage2 + + GroupBox1 - - 10 + + 8 - - 8, 30 + + True - - 288, 25 + + 22, 155 - - 24 + + 183, 16 - - txtServer + + 21 - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Installationspfad Sumatra: - - TabPage2 + + lblSumatra - - 11 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 4, 26 + + GroupBox1 - - 3, 3, 3, 3 + + 10 - - 832, 318 + + 10, 22 - - 1 + + 573, 23 - - Datenbankverbindung: + + 13 - - TabPage2 + + txtUniversalViewer - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - TabControl1 + + TabPage1 - - 1 + + 2 - + True - - 52, 165 - - - 55, 17 + + 510, 57 - - 45 + + 182, 21 - - Minuten + + 35 - - Label7 + + Windows-Authentifizierung - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + chkbxUserAut - - TabPage3 + + System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 0 + + TabPage2 - - 8, 162 + + 2 - - 38, 25 + + True - - 44 + + 5, 136 - - Center + + 164, 17 - - txtIntervall + + 34 - - System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Aktueller ConnectionString: - - TabPage3 + + Label5 - - 1 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - True + + TabPage2 - - 5, 142 + + 3 - - 159, 17 + + 8, 103 - - 43 + + 252, 25 - - Intervall Popup-Reminder: + + 27 - - Label6 + + cmbDatenbank - - System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.ComboBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - TabPage3 + + TabPage2 - - 2 + + 4 - - MiddleLeft + + True - - 8, 99 + + 5, 83 - - 219, 28 + + 73, 17 - - 42 + + 32 - - Öffne Log-Verzeichnis + + Datenbank: - - btnopenlog + + Label4 - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - TabPage3 + + TabPage2 - - 3 + + 5 - + True - - 506, 28 - - - 117, 21 + + 5, 35 - - 41 + + 88, 17 - - Log Errors only + + 29 - - chkLogErrorsOnly + + Server-Name: - - System.Windows.Forms.CheckBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Label1 - - TabPage3 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 4 + + TabPage2 - - 8, 64 + + 6 - - 219, 29 + + True - - 40 + + 299, 35 - - Open Appdata-Folder + + 93, 17 - - Button3 + + 30 - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Benutzername: - - TabPage3 + + Label2 - - 5 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - True + + TabPage2 - - 233, 29 + + 7 - - 166, 17 + + True - - 39 + + 423, 35 - - Support-Portal Digital Data + + 63, 17 - - LinkLabel1 + + 31 - - System.Windows.Forms.LinkLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + Passwort: - - TabPage3 + + Label3 - - 6 + + System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 506, 99 + + TabPage2 - - 219, 28 + + 8 - - 38 + + 302, 55 - - List all processes + + 118, 25 - - Button2 + + 25 - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + txtUser - - TabPage3 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 7 + + TabPage2 - - 506, 64 + + 9 - - 219, 29 + + 426, 55 - - 37 + + 64, 25 - - Get Culture Info + + 26 - - Button1 + + txtPasswort - - System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - TabPage3 + + TabPage2 - - 8 + + 10 - + MiddleLeft - - 8, 17 + + 302, 103 - - 219, 41 + + 253, 25 - - 0 + + 28 - - Log/Support Mail erzeugen + + Verbindung zur Datenbank herstellen - + MiddleRight - - btnLogMail + + BtnConnect - + System.Windows.Forms.Button, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - TabPage3 - - - 9 - - - 4, 26 + + TabPage2 - - 3, 3, 3, 3 + + 11 - - 832, 318 + + Top, Left, Right - - 2 + + 8, 156 - - Weiteres + + 744, 25 - - TabPage3 + + 33 - - System.Windows.Forms.TabPage, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + txtActualConnection - - TabControl1 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - 2 + + TabPage2 - - Fill + + 12 - - 0, 0 + + 8, 55 - - 840, 348 + + 288, 25 - - 21 + + 24 - - TabControl1 + + txtServer - - System.Windows.Forms.TabControl, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + System.Windows.Forms.TextBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - $this + + TabPage2 - - 0 + + 13 159, 17 @@ -1242,6 +1542,63 @@ 841, 17 + + True + + + 8, 6 + + + 148, 21 + + + 36 + + + Normale Verbindung + + + RadioDefaultConnection + + + System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + TabPage2 + + + 1 + + + True + + + NoControl + + + 173, 6 + + + 158, 21 + + + 36 + + + Alternative Verbindung + + + RadioAlternativeConnection + + + System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + TabPage2 + + + 0 + True diff --git a/app/DD_PM_WINDREAM/frmKonfig.vb b/app/DD_PM_WINDREAM/frmKonfig.vb index 880201a..dc9670c 100644 --- a/app/DD_PM_WINDREAM/frmKonfig.vb +++ b/app/DD_PM_WINDREAM/frmKonfig.vb @@ -150,12 +150,17 @@ Public Class frmKonfig oEncryptedConnectionString = oPlainConnectionString End If - 'SaveMySettingsValue("MyConnectionString", con) - 'My.Settings.Save() - - CONNECTION_STRING = oPlainConnectionString - CONFIG.Config.ConnectionString = oEncryptedConnectionString - CONFIG.Save() + If RadioDefaultConnection.Checked Then + LOGGER.Debug("ConnectionString saved") + CONNECTION_STRING = oPlainConnectionString + CONFIG.Config.ConnectionString = oEncryptedConnectionString + CONFIG.Save(ForceAll:=True) + Else + LOGGER.Debug("ConnectionStringTest saved") + CONNECTION_STRING = oPlainConnectionString + CONFIG.Config.ConnectionStringTest = oEncryptedConnectionString + CONFIG.Save(ForceAll:=True) + End If Load_ConString(CONNECTION_STRING) Me.TBPM_KONFIGURATIONTableAdapter.Connection.ConnectionString = CONNECTION_STRING @@ -320,15 +325,20 @@ Public Class frmKonfig End If End Sub Sub Load_ConString(constr As String) - If constr <> "" And constr.Contains("Password") Then - Dim csb As New SqlClient.SqlConnectionStringBuilder - csb.ConnectionString = CONNECTION_STRING - constr = constr.Replace(csb.Password, "XXXXX") - End If - - Me.txtActualConnection.Text = constr + txtActualConnection.Text = MaskConnectionStringPassword(constr) End Sub + Private Function MaskConnectionStringPassword(ConnectionString As String) As String + If ConnectionString.Contains("Password=") Then + Dim oBuilder As New SqlClient.SqlConnectionStringBuilder() With { + .ConnectionString = ConnectionString + } + Return ConnectionString.Replace(oBuilder.Password, "XXXXXX") + End If + + Return ConnectionString + End Function + Private Sub LinkLabel1_LinkClicked(sender As Object, e As LinkLabelLinkClickedEventArgs) Handles LinkLabel1.LinkClicked ' Specify that the link was visited. Me.LinkLabel1.LinkVisited = True @@ -357,4 +367,14 @@ Public Class frmKonfig CONFIG.Save() 'SaveMySettingsValue("LogErrorsOnly", chkLogErrorsOnly.Checked) End Sub + + Private Sub RadioDefaultConnection_CheckedChanged(sender As Object, e As EventArgs) Handles RadioDefaultConnection.CheckedChanged + txtActualConnection.Text = MaskConnectionStringPassword(CONFIG.Config.ConnectionString) + + + End Sub + + Private Sub RadioAlternativeConnection_CheckedChanged(sender As Object, e As EventArgs) Handles RadioAlternativeConnection.CheckedChanged + txtActualConnection.Text = MaskConnectionStringPassword(CONFIG.Config.ConnectionStringTest) + End Sub End Class \ No newline at end of file