Prüfung auf DB-Verbindung bei starten des Addins -> bei Fehler entsprechende Fehlermeldung inkl. Beendigung des Programmes

This commit is contained in:
2022-11-07 15:38:31 +01:00
parent 02f1fa1c68
commit 5c8d8e4eb7
7 changed files with 149 additions and 124 deletions

View File

@@ -5,18 +5,18 @@ VisualStudioVersion = 17.3.32825.248
MinimumVisualStudioVersion = 10.0.40219.1
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "VERAGAddIn", "VERAGAddIn\VERAGAddIn.vbproj", "{D579F7A6-7D29-4295-B382-DA5F7EFB4528}"
EndProject
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "VERAG_PROG_ALLGEMEIN", "..\SDL\SDL\VERAG_PROG_ALLGEMEIN\VERAG_PROG_ALLGEMEIN.vbproj", "{A3B497BD-842C-4A2B-B398-ED1976849DF1}"
EndProject
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "Gemeinsames", "..\AVISO\Aviso\Gemeinsames\Gemeinsames.vbproj", "{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}"
EndProject
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "Aviso", "..\AVISO\Aviso\Aviso\Aviso.vbproj", "{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}"
EndProject
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "TELOTEC_Worker_lib", "..\..\ADMIN\ADMIN\TELOTEK_Worker_lib\TELOTEC_Worker_lib.vbproj", "{5B947A66-009A-4BB6-B925-F84A01045095}"
EndProject
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "Parkzeit", "..\..\Parkzeit\Parkzeit\Parkzeit\Parkzeit.vbproj", "{E4190547-B222-4AE3-A0BE-A44EAEE70335}"
EndProject
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "SDL", "..\..\SDL\SDL\SDL\SDL.vbproj", "{289BCD77-BC00-4BA1-95ED-A79176D99525}"
EndProject
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "Aviso", "..\..\Aviso\AVISO\Aviso\Aviso.vbproj", "{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}"
EndProject
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "Gemeinsames", "..\..\Aviso\AVISO\Gemeinsames\Gemeinsames.vbproj", "{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}"
EndProject
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "VERAG_PROG_ALLGEMEIN", "..\..\SDL\SDL\VERAG_PROG_ALLGEMEIN\VERAG_PROG_ALLGEMEIN.vbproj", "{A3B497BD-842C-4A2B-B398-ED1976849DF1}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -43,48 +43,6 @@ Global
{D579F7A6-7D29-4295-B382-DA5F7EFB4528}.Release|x64.ActiveCfg = Release|Any CPU
{D579F7A6-7D29-4295-B382-DA5F7EFB4528}.Release|x64.Build.0 = Release|Any CPU
{D579F7A6-7D29-4295-B382-DA5F7EFB4528}.Release|x86.ActiveCfg = Release|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|x64.ActiveCfg = Debug|x64
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|x64.Build.0 = Debug|x64
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|x86.ActiveCfg = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|Any CPU.Build.0 = Release|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|x64.ActiveCfg = Release|x64
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|x64.Build.0 = Release|x64
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|x86.ActiveCfg = Release|Any CPU
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|Any CPU.ActiveCfg = Debug|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|Mixed Platforms.ActiveCfg = Debug|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|Mixed Platforms.Build.0 = Debug|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|x64.ActiveCfg = Debug|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|x64.Build.0 = Debug|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|x86.ActiveCfg = Debug|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|x86.Build.0 = Debug|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|Any CPU.ActiveCfg = Release|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|Mixed Platforms.ActiveCfg = Release|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|Mixed Platforms.Build.0 = Release|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|x64.ActiveCfg = Release|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|x64.Build.0 = Release|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|x86.ActiveCfg = Release|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|x86.Build.0 = Release|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|Any CPU.ActiveCfg = Debug|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|Mixed Platforms.ActiveCfg = Debug|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|Mixed Platforms.Build.0 = Debug|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|x64.ActiveCfg = Debug|x64
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|x64.Build.0 = Debug|x64
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|x86.ActiveCfg = Debug|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|x86.Build.0 = Debug|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|Any CPU.ActiveCfg = Release|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|Mixed Platforms.ActiveCfg = Release|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|Mixed Platforms.Build.0 = Release|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|x64.ActiveCfg = Release|x64
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|x64.Build.0 = Release|x64
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|x86.ActiveCfg = Release|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|x86.Build.0 = Release|x86
{5B947A66-009A-4BB6-B925-F84A01045095}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{5B947A66-009A-4BB6-B925-F84A01045095}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5B947A66-009A-4BB6-B925-F84A01045095}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
@@ -133,6 +91,54 @@ Global
{289BCD77-BC00-4BA1-95ED-A79176D99525}.Release|x64.Build.0 = Release|Any CPU
{289BCD77-BC00-4BA1-95ED-A79176D99525}.Release|x86.ActiveCfg = Release|Any CPU
{289BCD77-BC00-4BA1-95ED-A79176D99525}.Release|x86.Build.0 = Release|Any CPU
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|Mixed Platforms.ActiveCfg = Debug|x64
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|Mixed Platforms.Build.0 = Debug|x64
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|x64.ActiveCfg = Debug|x64
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|x64.Build.0 = Debug|x64
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|x86.ActiveCfg = Debug|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Debug|x86.Build.0 = Debug|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|Any CPU.Build.0 = Release|Any CPU
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|Mixed Platforms.ActiveCfg = Release|x64
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|Mixed Platforms.Build.0 = Release|x64
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|x64.ActiveCfg = Release|x64
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|x64.Build.0 = Release|x64
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|x86.ActiveCfg = Release|x86
{7BDD8C2F-2C9E-49F1-A365-3B1DA1C84991}.Release|x86.Build.0 = Release|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|Any CPU.ActiveCfg = Debug|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|Any CPU.Build.0 = Debug|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|Mixed Platforms.ActiveCfg = Debug|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|Mixed Platforms.Build.0 = Debug|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|x64.ActiveCfg = Debug|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|x64.Build.0 = Debug|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|x86.ActiveCfg = Debug|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Debug|x86.Build.0 = Debug|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|Any CPU.ActiveCfg = Release|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|Any CPU.Build.0 = Release|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|Mixed Platforms.ActiveCfg = Release|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|Mixed Platforms.Build.0 = Release|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|x64.ActiveCfg = Release|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|x64.Build.0 = Release|x64
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|x86.ActiveCfg = Release|x86
{110C923B-CB02-4FD0-AF24-95E0F0EEEFF5}.Release|x86.Build.0 = Release|x86
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|Mixed Platforms.ActiveCfg = Debug|x64
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|Mixed Platforms.Build.0 = Debug|x64
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|x64.ActiveCfg = Debug|x64
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|x64.Build.0 = Debug|x64
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|x86.ActiveCfg = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|x86.Build.0 = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|Any CPU.Build.0 = Release|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|Mixed Platforms.ActiveCfg = Release|x64
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|Mixed Platforms.Build.0 = Release|x64
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|x64.ActiveCfg = Release|x64
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|x64.Build.0 = Release|x64
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|x86.ActiveCfg = Release|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE

View File

@@ -14,7 +14,7 @@ Option Explicit On
<Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "15.9.0.0"), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "17.3.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
Partial Friend NotInheritable Class MySettings
Inherits Global.System.Configuration.ApplicationSettingsBase

View File

@@ -21,7 +21,7 @@ Partial Public NotInheritable Class ThisAddIn
Friend WithEvents CustomTaskPanes As Microsoft.Office.Tools.CustomTaskPaneCollection
<Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0")> _
<Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0")> _
Friend WithEvents Application As Microsoft.Office.Interop.Outlook.Application
'''
@@ -34,7 +34,7 @@ Partial Public NotInheritable Class ThisAddIn
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0"), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Protected Overrides Sub Initialize()
MyBase.Initialize
@@ -49,7 +49,7 @@ Partial Public NotInheritable Class ThisAddIn
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0"), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Protected Overrides Sub FinishInitialization()
Me.OnStartup
@@ -57,7 +57,7 @@ Partial Public NotInheritable Class ThisAddIn
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0"), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Protected Overrides Sub InitializeDataBindings()
Me.BeginInitialization
@@ -67,7 +67,7 @@ Partial Public NotInheritable Class ThisAddIn
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0"), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub InitializeCachedData()
If (Me.DataHost Is Nothing) Then
@@ -80,14 +80,14 @@ Partial Public NotInheritable Class ThisAddIn
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0"), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub InitializeData()
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0"), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub BindToData()
End Sub
@@ -115,7 +115,7 @@ Partial Public NotInheritable Class ThisAddIn
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0"), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub BeginInitialization()
Me.BeginInit
@@ -124,7 +124,7 @@ Partial Public NotInheritable Class ThisAddIn
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0"), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub EndInitialization()
Me.CustomTaskPanes.EndInit
@@ -133,7 +133,7 @@ Partial Public NotInheritable Class ThisAddIn
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0"), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub InitializeControls()
Me.CustomTaskPanes = Globals.Factory.CreateCustomTaskPaneCollection(Nothing, Nothing, "CustomTaskPanes", "CustomTaskPanes", Me)
@@ -141,7 +141,7 @@ Partial Public NotInheritable Class ThisAddIn
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0"), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub InitializeComponents()
End Sub
@@ -155,7 +155,7 @@ Partial Public NotInheritable Class ThisAddIn
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0"), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Protected Overrides Sub OnShutdown()
Me.CustomTaskPanes.Dispose
@@ -165,7 +165,7 @@ End Class
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0")> _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0")> _
Partial Friend NotInheritable Class Globals
'''
@@ -228,7 +228,7 @@ End Class
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "15.0.0.0")> _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "17.0.0.0")> _
Partial Friend NotInheritable Class ThisRibbonCollection
Inherits Microsoft.Office.Tools.Ribbon.RibbonCollectionBase

View File

@@ -177,6 +177,10 @@
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="VERAG_PROG_ALLGEMEIN, Version=1.0.0.0, Culture=neutral, processorArchitecture=AMD64">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\SDL\SDL\VERAG_PROG_ALLGEMEIN\bin\Debug\VERAG_PROG_ALLGEMEIN.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Reference Include="Microsoft.Office.Tools.v4.0.Framework, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL" />
@@ -350,10 +354,6 @@
<Project>{289bcd77-bc00-4ba1-95ed-a79176d99525}</Project>
<Name>SDL</Name>
</ProjectReference>
<ProjectReference Include="..\..\SDL\SDL\VERAG_PROG_ALLGEMEIN\VERAG_PROG_ALLGEMEIN.vbproj">
<Project>{a3b497bd-842c-4a2b-b398-ed1976849df1}</Project>
<Name>VERAG_PROG_ALLGEMEIN</Name>
</ProjectReference>
</ItemGroup>
<PropertyGroup>
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>

View File

@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">

View File

@@ -1,4 +1,6 @@
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()>
Imports VERAG_PROG_ALLGEMEIN
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()>
Partial Class frmAvisoFormularAnfuegen
Inherits System.Windows.Forms.Form

View File

@@ -9,13 +9,15 @@ Imports System.Runtime.InteropServices
Imports System.Text.RegularExpressions
Imports System.IO
Imports SDL
Imports System.Net
Imports System.Security.Policy
Imports System.Diagnostics.Eventing.Reader
Public Class VERAGRibbon
Dim LOGIN_OK = False
Public Shared Event bla()
Private Sub CustomerRibbon_Load(ByVal sender As System.Object, ByVal e As Microsoft.Office.Tools.Ribbon.RibbonUIEventArgs) Handles MyBase.Load
End Sub
Private Function CreateRibbonDropDownItem() As RibbonDropDownItem
Return Me.Factory.CreateRibbonDropDownItem()
@@ -36,6 +38,9 @@ Public Class VERAGRibbon
'VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM = False
VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM = True
LOGIN_OK = AVISO_Mail_Functions.initFirmaUser()
If testConnection() = False Then
Windows.Forms.Application.Exit()
End If
End Sub
@@ -77,11 +82,24 @@ Public Class VERAGRibbon
End Sub
Private Sub btnVM_Click(sender As Object, e As RibbonControlEventArgs) Handles btnVM.Click
' ToDo -> Logik für das Einfügen eines PDFs aus einer Mail in eine Vollmacht im Aviso.
If LOGIN_OK Then AVISO_Mail_Functions.addMailToAviso_Hauptfenster(True)
End Sub
Public Function testConnection() As Boolean
Dim connection = New VERAG_PROG_ALLGEMEIN.SQL
If connection.getValueTxtBySql("SELECT 1", "FMZOLL") = 1 Then
Return True
Else
MsgBox("ACHTUNG: Server nicht erreichbar!" & vbCrLf & "VERAG ADD In wird beendet")
Return False
End If
End Function
End Class
Public Class AVISO_Mail_Functions
@@ -135,7 +153,13 @@ Public Class AVISO_Mail_Functions
End If
End If
Dim Bezeichnung = strFileName
Dim AvisoId = getAvisoId(Bezeichnung, pdf_mail, SendungsId, Art, ATTACHMENTS_LIST, kdNr, isFormular) ')getAttachmentStringList(mailItem))
Dim AvisoId = Nothing
If isFormular Then
AvisoId = getAvisoFormularId(Bezeichnung, pdf_mail, Art, ATTACHMENTS_LIST, kdNr) ')getAttachmentStringList(mailItem))
Else
AvisoId = getAvisoId(Bezeichnung, pdf_mail, SendungsId, Art, ATTACHMENTS_LIST) ')getAttachmentStringList(mailItem))
End If
If AvisoId < 0 Then Exit Sub
Dim BezAnhang = If(Bezeichnung <> strFileName, Bezeichnung, "") 'Wenn die Bezeichnung geändert wurde --> und wenn nur 1 Anhang, dann wird die Bezeichnung für den Anhang verwendet.
@@ -146,10 +170,10 @@ Public Class AVISO_Mail_Functions
saveMail(mailItem, AvisoId, Bezeichnung,, SendungsId, Art)
saveAttachment(ATTACHMENTS_LIST, AvisoId, SendungsId, Art, BezAnhang)
ElseIf pdf_mail = "PDF_DATENSERVER" Then
saveMailOnDatenserver(mailItem, AvisoId, Bezeichnung,, Art, kdNr, True)
saveAttachmentOnDatenserver(ATTACHMENTS_LIST, AvisoId, Art, BezAnhang, kdNr, True)
saveMailOnDatenserver(mailItem, AvisoId, Bezeichnung,, kdNr)
saveAttachmentOnDatenserver(ATTACHMENTS_LIST, AvisoId, BezAnhang, kdNr)
ElseIf pdf_mail = "ONLYMAIL_DATENSERVER" Then
saveMailOnDatenserver(mailItem, AvisoId, Bezeichnung,, Art, kdNr)
saveMailOnDatenserver(mailItem, AvisoId, Bezeichnung,, kdNr)
Else 'ONLYMAIL
saveMail(mailItem, AvisoId, Bezeichnung,, SendungsId, Art)
End If
@@ -395,7 +419,7 @@ Public Class AVISO_Mail_Functions
End Try
End Sub
Shared Sub saveAttachmentOnDatenserver(ByRef ATTACHMENTS_LIST As List(Of String), AvisoId As Integer, Art As String, BezeichnungAnh As String, Optional kdNr As Integer = -1, Optional multifiles As Boolean = False)
Shared Sub saveAttachmentOnDatenserver(ByRef ATTACHMENTS_LIST As List(Of String), AvisoId As Integer, BezeichnungAnh As String, Optional kdNr As Integer = -1)
Try
If AvisoId > 0 Then
If ATTACHMENTS_LIST.Count > 1 Then BezeichnungAnh = "" ' nur wenn 1 Anhang wird die Bezeichnung übernommen.
@@ -404,12 +428,8 @@ Public Class AVISO_Mail_Functions
Dim Bezeichnung = BezeichnungAnh
If Bezeichnung = "" Then Bezeichnung = fi.Name
Dim DS As Object = Nothing
If multifiles Then
DS = New VERAG_PROG_ALLGEMEIN.cDATENSERVER("DOKUMENTE", "VOLLMACHTEN", "VMID_" & AvisoId, "", "", Bezeichnung, kdNr, multifiles)
Else
DS = New VERAG_PROG_ALLGEMEIN.cDATENSERVER("DOKUMENTE", "VOLLMACHTEN", "VMID_" & AvisoId, "", "", Bezeichnung)
End If
Dim DS = New VERAG_PROG_ALLGEMEIN.cDATENSERVER("DOKUMENTE", "VOLLMACHTEN", "VMID_" & AvisoId, "", "", Bezeichnung, kdNr)
Dim path = DS.uploadDataToDATENSERVER(fi.FullName)
If path Then
Dim c As New cKundenVollmachten(AvisoId)
@@ -425,10 +445,6 @@ Public Class AVISO_Mail_Functions
MsgBox(System.Reflection.MethodInfo.GetCurrentMethod.Name & ex.Message & ex.StackTrace)
End Try
End Sub
@@ -553,9 +569,14 @@ Public Class AVISO_Mail_Functions
If cnt > 0 AndAlso l.Contains(""">") Then ' ENDE
Dim link = ("https://web01.ekol.com/documentservice/download/" & l.ToString.Substring(0, l.ToString.IndexOf(""">")))
'Ansonten stüzt der Webservice-Aufruf ab! ABER -> For .NET 4.7 or later, the System.Net.ServicePointManager.SecurityProtocol should not be set manualy!
System.Net.ServicePointManager.SecurityProtocol = System.Net.ServicePointManager.SecurityProtocol Or SecurityProtocolType.Tls11 Or SecurityProtocolType.Tls12
Dim TMP_PATH = GetTempFilePathWithExtension(".pdf")
My.Computer.Network.DownloadFile(link, TMP_PATH)
If IO.File.Exists(TMP_PATH) Then
ATT.Add(TMP_PATH)
End If
@@ -620,7 +641,7 @@ Public Class AVISO_Mail_Functions
End Try
End Sub
Shared Sub saveMailOnDatenserver(mailItem As Outlook.MailItem, AvisoId As Integer, Optional bezeichnung As String = "", Optional saveAttachments As Boolean = True, Optional Art As String = "", Optional kdNr As Integer = -1, Optional multifiles As Boolean = False)
Shared Sub saveMailOnDatenserver(mailItem As Outlook.MailItem, AvisoId As Integer, Optional bezeichnung As String = "", Optional saveAttachments As Boolean = True, Optional kdNr As Integer = -1)
Try
If AvisoId > 0 Then
@@ -630,16 +651,11 @@ Public Class AVISO_Mail_Functions
mailItem.SaveAs(strTmpPath, Outlook.OlSaveAsType.olMSG)
Dim DS As Object = Nothing
If multifiles Then
DS = New VERAG_PROG_ALLGEMEIN.cDATENSERVER("DOKUMENTE", "VOLLMACHTEN", "VMID_" & AvisoId, "", "", bezeichnung, kdNr, multifiles)
Else
DS = New VERAG_PROG_ALLGEMEIN.cDATENSERVER("DOKUMENTE", "VOLLMACHTEN", "VMID_" & AvisoId, "", "", bezeichnung)
End If
Dim DS = New VERAG_PROG_ALLGEMEIN.cDATENSERVER("DOKUMENTE", "VOLLMACHTEN", "VMID_" & AvisoId, "", "", bezeichnung, kdNr)
Dim path = DS.uploadDataToDATENSERVER(strTmpPath)
If path Then
Dim c As New cKundenVollmachten(AvisoId)
c.kdvm_datenarchivId = DS.da_id
c.kdvm_emailId = DS.da_id
c.SAVE()
End If
@@ -657,28 +673,8 @@ Public Class AVISO_Mail_Functions
End Sub
Shared Function getAvisoId(ByRef Bezeichnung, ByRef pdf_mail, ByRef SendungsId, ByRef Art, ByRef Att, ByVal isFormular, ByRef kdNr) As Integer
Shared Function getAvisoId(ByRef Bezeichnung, ByRef pdf_mail, ByRef SendungsId, ByRef Art, ByRef Att) As Integer
If (isFormular = True) Then
Dim frmAvisoFormularAnfuegen As New frmAvisoFormularAnfuegen(Bezeichnung)
frmAvisoFormularAnfuegen.ATT = Att
If frmAvisoFormularAnfuegen.ShowDialog = DialogResult.OK Then
Dim AvisoId = frmAvisoFormularAnfuegen.vollmachtId
kdNr = frmAvisoFormularAnfuegen.KdNr
SendungsId = frmAvisoFormularAnfuegen.SendungsId
Bezeichnung = frmAvisoFormularAnfuegen.Bezeichnung
pdf_mail = frmAvisoFormularAnfuegen.PDF_MAIL
Att = frmAvisoFormularAnfuegen.ATT
Return AvisoId
End If
Return -1
Exit Function
End If
Dim frmAvisoAnfügen As New frmAvisoAnfuegen(Bezeichnung)
frmAvisoAnfügen.ATT = Att
@@ -697,4 +693,25 @@ Public Class AVISO_Mail_Functions
End Function
Shared Function getAvisoFormularId(ByRef Bezeichnung, ByRef pdf_mail, ByRef Art, ByRef Att, ByRef kdNr) As Integer
Dim frmAvisoFormularAnfuegen As New frmAvisoFormularAnfuegen(Bezeichnung)
frmAvisoFormularAnfuegen.ATT = Att
If frmAvisoFormularAnfuegen.ShowDialog = DialogResult.OK Then
Dim AvisoId = frmAvisoFormularAnfuegen.vollmachtId
kdNr = frmAvisoFormularAnfuegen.KdNr
Bezeichnung = frmAvisoFormularAnfuegen.Bezeichnung
pdf_mail = frmAvisoFormularAnfuegen.PDF_MAIL
Att = frmAvisoFormularAnfuegen.ATT
Return AvisoId
End If
Return -1
End Function
End Class