From 1b24e778aeee0cfd0a3d8bd11fe3e87d11f00a60 Mon Sep 17 00:00:00 2001 From: OlgunR Date: Thu, 15 May 2025 11:35:09 +0200 Subject: [PATCH] Support Link wird aus der DB geholt und ist nicht mehr hardcoded - frmConfigBasic --- Global_Indexer/frmConfig_Basic.designer.vb | 18 +++--- Global_Indexer/frmConfig_Basic.resx | 68 +++++++++++----------- Global_Indexer/frmConfig_Basic.vb | 21 +++++-- 3 files changed, 59 insertions(+), 48 deletions(-) diff --git a/Global_Indexer/frmConfig_Basic.designer.vb b/Global_Indexer/frmConfig_Basic.designer.vb index d5f01ca..d8850e4 100644 --- a/Global_Indexer/frmConfig_Basic.designer.vb +++ b/Global_Indexer/frmConfig_Basic.designer.vb @@ -39,10 +39,10 @@ Partial Class frmConfig_Basic Me.txtPasswort = New System.Windows.Forms.TextBox() Me.BtnConnect = New System.Windows.Forms.Button() Me.TabPage2 = New System.Windows.Forms.TabPage() + Me.LinkLabel_SupportPortal = New System.Windows.Forms.LinkLabel() Me.Label10 = New System.Windows.Forms.Label() Me.Button5 = New System.Windows.Forms.Button() Me.cmbDesign = New System.Windows.Forms.ComboBox() - Me.LinkLabel1 = New System.Windows.Forms.LinkLabel() Me.Button3 = New System.Windows.Forms.Button() Me.cmbLanguage = New System.Windows.Forms.ComboBox() Me.Label9 = New System.Windows.Forms.Label() @@ -172,10 +172,10 @@ Partial Class frmConfig_Basic ' 'TabPage2 ' + Me.TabPage2.Controls.Add(Me.LinkLabel_SupportPortal) Me.TabPage2.Controls.Add(Me.Label10) Me.TabPage2.Controls.Add(Me.Button5) Me.TabPage2.Controls.Add(Me.cmbDesign) - Me.TabPage2.Controls.Add(Me.LinkLabel1) Me.TabPage2.Controls.Add(Me.Button3) Me.TabPage2.Controls.Add(Me.cmbLanguage) Me.TabPage2.Controls.Add(Me.Label9) @@ -188,6 +188,12 @@ Partial Class frmConfig_Basic Me.TabPage2.Name = "TabPage2" Me.TabPage2.UseVisualStyleBackColor = True ' + 'LinkLabel_SupportPortal + ' + resources.ApplyResources(Me.LinkLabel_SupportPortal, "LinkLabel_SupportPortal") + Me.LinkLabel_SupportPortal.Name = "LinkLabel_SupportPortal" + Me.LinkLabel_SupportPortal.TabStop = True + ' 'Label10 ' resources.ApplyResources(Me.Label10, "Label10") @@ -206,12 +212,6 @@ Partial Class frmConfig_Basic Me.cmbDesign.Items.AddRange(New Object() {resources.GetString("cmbDesign.Items"), resources.GetString("cmbDesign.Items1"), resources.GetString("cmbDesign.Items2"), resources.GetString("cmbDesign.Items3"), resources.GetString("cmbDesign.Items4"), resources.GetString("cmbDesign.Items5"), resources.GetString("cmbDesign.Items6")}) Me.cmbDesign.Name = "cmbDesign" ' - 'LinkLabel1 - ' - resources.ApplyResources(Me.LinkLabel1, "LinkLabel1") - Me.LinkLabel1.Name = "LinkLabel1" - Me.LinkLabel1.TabStop = True - ' 'Button3 ' resources.ApplyResources(Me.Button3, "Button3") @@ -424,8 +424,8 @@ Partial Class frmConfig_Basic Friend WithEvents cmbLanguage As System.Windows.Forms.ComboBox Friend WithEvents Label9 As System.Windows.Forms.Label Friend WithEvents Button3 As System.Windows.Forms.Button - Friend WithEvents LinkLabel1 As System.Windows.Forms.LinkLabel Friend WithEvents Label10 As Label Friend WithEvents Button5 As Button Friend WithEvents cmbDesign As ComboBox + Friend WithEvents LinkLabel_SupportPortal As LinkLabel End Class diff --git a/Global_Indexer/frmConfig_Basic.resx b/Global_Indexer/frmConfig_Basic.resx index d385e85..e41ea61 100644 --- a/Global_Indexer/frmConfig_Basic.resx +++ b/Global_Indexer/frmConfig_Basic.resx @@ -427,7 +427,7 @@ 3, 3, 3, 3 - 582, 280 + 526, 275 0 @@ -447,6 +447,33 @@ 0 + + True + + + 8, 235 + + + 153, 13 + + + 49 + + + Support Portal - Digital Data + + + LinkLabel_SupportPortal + + + System.Windows.Forms.LinkLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + TabPage2 + + + 0 + True @@ -475,7 +502,7 @@ TabPage2 - 0 + 1 Segoe UI, 8.25pt @@ -505,7 +532,7 @@ TabPage2 - 1 + 2 Segoe UI, 8.25pt @@ -550,33 +577,6 @@ TabPage2 - 2 - - - True - - - 8, 226 - - - 153, 13 - - - 45 - - - Support Portal - Digital Data - - - LinkLabel1 - - - System.Windows.Forms.LinkLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - TabPage2 - - 3 @@ -809,7 +809,7 @@ 3, 3, 3, 3 - 526, 244 + 526, 275 1 @@ -1176,7 +1176,7 @@ ausgenommen werden sollen: 3, 3, 3, 3 - 582, 280 + 526, 275 2 @@ -1203,7 +1203,7 @@ ausgenommen werden sollen: 0, 0 - 534, 270 + 534, 301 0 @@ -1230,7 +1230,7 @@ ausgenommen werden sollen: 6, 13 - 534, 270 + 534, 301 Segoe UI, 8.25pt diff --git a/Global_Indexer/frmConfig_Basic.vb b/Global_Indexer/frmConfig_Basic.vb index c100595..7e76d0c 100644 --- a/Global_Indexer/frmConfig_Basic.vb +++ b/Global_Indexer/frmConfig_Basic.vb @@ -518,11 +518,22 @@ Public Class frmConfig_Basic End If End Sub - Private Sub LinkLabel1_LinkClicked(sender As Object, e As LinkLabelLinkClickedEventArgs) Handles LinkLabel1.LinkClicked - ' Specify that the link was visited. - Me.LinkLabel1.LinkVisited = True - ' Navigate to a URL. - Process.Start("https://www.digitaldata.works/Support") + Private Sub LinkLabel_SupportPortal_LinkClicked(sender As Object, e As LinkLabelLinkClickedEventArgs) Handles LinkLabel_SupportPortal.LinkClicked + Try + Me.LinkLabel_SupportPortal.LinkVisited = True + + Dim oSql As String = "SELECT CAT_STRING FROM TBDD_CATALOG WHERE CAT_TITLE = 'DDSUPPORT_PORTAL'" + Dim oSupportLink As String = DATABASE_ECM.GetScalarValue(oSql)?.ToString() + + If Not String.IsNullOrEmpty(oSupportLink) Then + Process.Start(oSupportLink) + Else + MsgBox("Support-Link nicht gefunden.", MsgBoxStyle.Information) + End If + + Catch ex As Exception + MsgBox("Fehler beim Öffnen des Support-Links: " & ex.Message, MsgBoxStyle.Critical) + End Try End Sub Private Sub Label10_Click(sender As Object, e As EventArgs) Handles Label10.Click