This commit is contained in:
2020-02-26 14:53:13 +01:00
parent 1496d02e59
commit 73cb093fdf
23 changed files with 404 additions and 302 deletions

View File

@@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
' übernehmen, indem Sie "*" eingeben: ' übernehmen, indem Sie "*" eingeben:
' <Assembly: AssemblyVersion("1.0.*")> ' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("2.0.0.0")> <Assembly: AssemblyVersion("2.0.0.1")>
<Assembly: AssemblyFileVersion("1.0.0.0")> <Assembly: AssemblyFileVersion("1.0.0.0")>

View File

@@ -308,7 +308,7 @@ Public Class clsDateiverarbeitung
Logger.Debug("tempFilename: " & tempFilename) Logger.Debug("tempFilename: " & tempFilename)
'Überprüfen ob File existiert 'Überprüfen ob File existiert
Do While IO.File.Exists(tempFilename) = True Do While IO.File.Exists(tempFilename) = True
tempFilename = ZielPfad & "\" & Filename & "~" & version & Extension tempFilename = ZielPfad & "\" & Filename & "_" & version & Extension
version += 1 version += 1
Loop Loop
Logger.Debug("RenameFile - OLDFilename: " & aktfile_Exportresult & " - NEWFilename: " & Path.GetFileName(tempFilename)) Logger.Debug("RenameFile - OLDFilename: " & aktfile_Exportresult & " - NEWFilename: " & Path.GetFileName(tempFilename))
@@ -353,7 +353,7 @@ Public Class clsDateiverarbeitung
Dim version As Integer = 2 Dim version As Integer = 2
'Überprüfen ob File existiert 'Überprüfen ob File existiert
Do While IO.File.Exists(tempFilename) = True Do While IO.File.Exists(tempFilename) = True
tempFilename = ZielPfad & "\" & WMvalue & "~" & version & Extension tempFilename = ZielPfad & "\" & WMvalue & "_" & version & Extension
version += 1 version += 1
Loop Loop
File.Copy(copybasefile, tempFilename, True) File.Copy(copybasefile, tempFilename, True)

View File

@@ -14,66 +14,6 @@ Public Class clsEmail
Sub New(MyLogger As LogConfig) Sub New(MyLogger As LogConfig)
Logger = MyLogger.GetLogger() Logger = MyLogger.GetLogger()
End Sub End Sub
Public Function Testmail(ByVal mailSubject As String, ByVal mailBody As String, mailto As String,
mailfrom As String, mailsmtp As String, mailport As Integer, mailUser As String, mailPW As String,
AUTH_TYPE As String, Optional attment As String = "")
Try
Dim oReceipiants As String()
If mailto.Contains(";") Then
oReceipiants = mailto.Split(";")
Else
ReDim Preserve oReceipiants(0)
oReceipiants(0) = mailto
End If
For Each oMailReceipiant As String In oReceipiants
Dim sClient = New Mail.SmtpClient(mailsmtp)
Dim mymesssage As New MailMessage
sClient.Port = mailport
If AUTH_TYPE = "SSL" Then
sClient.EnableSsl = True
Else
sClient.EnableSsl = False
End If
sClient.Credentials = New NetworkCredential(mailUser, mailPW)
sClient.UseDefaultCredentials = False
mymesssage.Body = $"This is the body (text will be replaced within profile)! <br> mailsmtp: {mailsmtp} <br> mailport: {mailport} <br> mailUser: {mailUser} <br> mailPW: XXXX <br> AUTH_TYPE: {AUTH_TYPE}"
Dim htmlView As AlternateView = AlternateView.CreateAlternateViewFromString(mymesssage.Body)
htmlView.ContentType = New System.Net.Mime.ContentType("text/html")
mymesssage.AlternateViews.Add(htmlView)
mymesssage.From = New MailAddress(mailfrom)
mymesssage.Subject = mailSubject
mymesssage.To.Add(New MailAddress(oMailReceipiant))
If attment <> String.Empty Then
Dim oAttment As String = attment.Replace("W:\", "\\windream\objects\")
If System.IO.File.Exists(oAttment) Then
Logger.Info($"working on attachment {oAttment}...")
Dim oAttachment As New System.Net.Mail.Attachment(oAttment)
mymesssage.Attachments.Add(oAttachment)
Else
MsgBox($"Attachment {oAttment.ToString} is not existing - Mail won't be send!")
Return False
End If
End If
sClient.Send(mymesssage)
Logger.Info($"Email has been send to {oMailReceipiant}!!")
Next
Return True
Catch ex As Exception
MsgBox(ex.Message, MsgBoxStyle.Critical)
Return False
End Try
End Function
Public Function Email_Send(ByVal mailSubject As String, ByVal mailBody As String, mailto As String, Public Function Email_Send(ByVal mailSubject As String, ByVal mailBody As String, mailto As String,
mailfrom As String, mailsmtp As String, mailport As Integer, mailUser As String, mailPW As String, mailfrom As String, mailsmtp As String, mailport As Integer, mailUser As String, mailPW As String,
AUTH_TYPE As String, Optional attment As String = "", Optional Test As Boolean = False) AUTH_TYPE As String, Optional attment As String = "", Optional Test As Boolean = False)
@@ -134,6 +74,7 @@ Public Class clsEmail
mymesssage.Subject = mailSubject mymesssage.Subject = mailSubject
mymesssage.To.Add(New MailAddress(oMailReceipiant)) mymesssage.To.Add(New MailAddress(oMailReceipiant))
sClient.Send(mymesssage) sClient.Send(mymesssage)
Logger.Info($"Email successfully send to: [{oMailReceipiant}]!")
Next Next
If oError = False Then If oError = False Then
Return True Return True
@@ -147,153 +88,4 @@ Public Class clsEmail
End Try End Try
End Function End Function
Public Function Email_Send_Independentsoft(ByVal mailSubject As String, ByVal mailBody As String, mailto As String,
mailfrom As String, mailsmtp As String, mailport As Integer, mailUser As String, mailPW As String,
AUTH_TYPE As String, Optional attment As String = "")
Try
Logger.Debug($"in Email_Send_Independentsoft..")
Dim empfaenger As String()
If mailto.Contains(";") Then
empfaenger = mailto.Split(";")
Else
ReDim Preserve empfaenger(0)
empfaenger(0) = mailto
End If
Dim _error As Boolean = False
'Für jeden Empfänger eine Neue Mail erzeugen
For Each _mailempfaenger As String In empfaenger
Logger.Debug($"Working on email for {_mailempfaenger}..")
Try
Dim message As New Message()
message.From = New Mailbox(mailfrom, mailfrom)
message.[To].Add(New Mailbox(_mailempfaenger))
message.Subject = mailSubject
Logger.Debug($"Message created..")
Dim textBodyPart As New BodyPart()
textBodyPart.ContentType = New Independentsoft.Email.Mime.ContentType("text", "html", "utf-8")
textBodyPart.ContentTransferEncoding = ContentTransferEncoding.QuotedPrintable
textBodyPart.Body = mailBody
message.BodyParts.Add(textBodyPart)
attment = attment.Replace("W:\", "\\windream\objects\")
If attment <> String.Empty Then
If System.IO.File.Exists(attment) Then
Logger.Info($"working on attachment {attment.ToString}...")
Dim attachment1 As New Independentsoft.Email.Mime.Attachment(attment)
If attment.ToLower.EndsWith("pdf") Then
attachment1.ContentType = New Independentsoft.Email.Mime.ContentType("application", "pdf")
ElseIf attment.ToLower.EndsWith("jpg") Then
attachment1.ContentType = New Independentsoft.Email.Mime.ContentType("application", "jpg")
ElseIf attment.ToLower.EndsWith("docx") Then
attachment1.ContentType = New Independentsoft.Email.Mime.ContentType("application", "MS-word")
End If
message.BodyParts.Add(attachment1)
Else
Logger.Warn($"Attachment {attment.ToString} is not existing - Mail won't be send!")
Return False
End If
End If
Dim client As Smtp.SmtpClient
Try
client = New Smtp.SmtpClient(mailsmtp, mailport)
Catch ex As Exception
Logger.Warn("clsEmail.Create Client: " & ex.Message)
_error = True
Continue For
End Try
'Try
' client.Connect()
'Catch ex As Exception
' Logger.Warn("clsEmail.Client.Connect: " & ex.Message)
' _error = True
' ' Continue For
'End Try
If AUTH_TYPE = "SSL" Then
client.EnableSsl = True
' client.ValidateRemoteCertificate = True
Logger.Info("Authentification via SSL.")
ElseIf AUTH_TYPE = "TLS" Then
' client.ValidateRemoteCertificate = False
client.StartTls()
client.EnableSsl = False
Logger.Info("Authentification via TLS. SSL disabled")
Else
client.EnableSsl = False
Logger.Info("Authentification NONE. SSL disabled")
End If
Try
client.Connect()
Logger.Info("Connected to Client!")
Catch ex As Exception
Logger.Warn("clsEmail.Client.Connect2: " & ex.Message)
_error = True
' Continue For
End Try
Try
If mailsmtp.Contains("office365.com") Then
client.Login(mailUser, mailPW, AuthenticationType.None)
Else
client.Login(mailUser, mailPW)
End If
Logger.Info("Logged in!")
Catch ex As Exception
Try
If mailsmtp.Contains("office365.com") Then
client.Login(mailUser, mailPW, AuthenticationType.Login)
Else
client.Login(mailUser, mailPW, AuthenticationType.None)
End If
Catch ex1 As Exception
Try
client.Login(mailUser, mailPW, AuthenticationType.Login)
Catch ex2 As Exception
Logger.Warn("clsEmail.Client.Login: " & ex.Message)
_error = True
client.Disconnect()
Continue For
End Try
End Try
End Try
Try
client.Send(message)
Logger.Info("Message to " & _mailempfaenger & " has been send.")
_error = False
Catch ex As Exception
Logger.Warn("clsEmail.Client.Send: " & ex.Message)
Try
client.Login(mailUser, mailPW, AuthenticationType.Login)
client.Send(message)
Catch ex1 As Exception
Logger.Warn("clsEmail.Client.Send2: " & ex.Message)
_error = True
client.Disconnect()
Continue For
End Try
End Try
client.Disconnect()
Catch ex As Exception
Logger.Error(ex)
_error = True
End Try
Next
If _error = True Then
Return False
Else
Return True
End If
Catch ex As Exception
Logger.Error(ex)
Return False
End Try
End Function
End Class End Class

View File

@@ -144,7 +144,7 @@ Public Class clsProfil
Return False Return False
End If End If
If windreamSucheErgebnisse.Count > 0 Then If windreamSucheErgebnisse.Count > 0 Then
Logger.Info(windreamSucheErgebnisse.Count & " files shall be worked!") Logger.Info(windreamSucheErgebnisse.Count & " file(s) shall be worked!")
Logger.Debug("SELECT * FROM TBWMRH_PROFIL_JOB WHERE AKTIV = 1 AND PROFIL_ID = " & _profGUID & " ORDER BY REIHENFOLGE") Logger.Debug("SELECT * FROM TBWMRH_PROFIL_JOB WHERE AKTIV = 1 AND PROFIL_ID = " & _profGUID & " ORDER BY REIHENFOLGE")
Dim DT_PROFIL_JOB As DataTable = _database.Return_Datatable("SELECT * FROM TBWMRH_PROFIL_JOB WHERE AKTIV = 1 AND PROFIL_ID = " & _profGUID & " ORDER BY REIHENFOLGE") Dim DT_PROFIL_JOB As DataTable = _database.Return_Datatable("SELECT * FROM TBWMRH_PROFIL_JOB WHERE AKTIV = 1 AND PROFIL_ID = " & _profGUID & " ORDER BY REIHENFOLGE")
@@ -169,7 +169,7 @@ Public Class clsProfil
For Each DR_PR_JB As DataRow In DT_PROFIL_JOB.Rows For Each DR_PR_JB As DataRow In DT_PROFIL_JOB.Rows
Select Case DR_PR_JB.Item("JOB_TYP").ToString.ToUpper Select Case DR_PR_JB.Item("JOB_TYP").ToString.ToUpper
Case "Create Mail Attachment".ToUpper Case "Create Mail Attachment".ToUpper
Logger.Info("JobType: Create Mail Attachment") Logger.Debug("JobType: Create Mail Attachment")
'XX 'XX
Dim Email_Empfänger = DR_PR_JB.Item("STRING1") Dim Email_Empfänger = DR_PR_JB.Item("STRING1")
@@ -243,7 +243,7 @@ Public Class clsProfil
End If End If
Case "Export HDD".ToUpper Case "Export HDD".ToUpper
Logger.Info($"{oFileRunNo} JobType: Case Export HDD") Logger.Debug($"{oFileRunNo} JobType: Case Export HDD")
'Für jedes Dokument in der Windream-Ergebnisliste 'Für jedes Dokument in der Windream-Ergebnisliste
'For Each dok As WMObject In windreamSucheErgebnisse 'For Each dok As WMObject In windreamSucheErgebnisse
' aktuelles Dokument zum Export bereitstellen ' aktuelles Dokument zum Export bereitstellen
@@ -257,7 +257,7 @@ Public Class clsProfil
End If End If
'Next 'Next
Case "BNS json Download".ToUpper Case "BNS json Download".ToUpper
Logger.Info($"{oFileRunNo} JobType: BNS json Download") Logger.Debug($"{oFileRunNo} JobType: BNS json Download")
FileJobSuccessful = _dateiverarbeitung.BNSjsonDownload(WMdok, DR_PR_JB.Item("STRING1"), DR_PR_JB.Item("STRING2")) FileJobSuccessful = _dateiverarbeitung.BNSjsonDownload(WMdok, DR_PR_JB.Item("STRING1"), DR_PR_JB.Item("STRING2"))
'Case "Send to printer".ToUpper 'Case "Send to printer".ToUpper
' Logger.Info("JobType: Send to printer") ' Logger.Info("JobType: Send to printer")
@@ -393,7 +393,6 @@ Public Class clsProfil
If arrValue Is Nothing = False Then If arrValue Is Nothing = False Then
' MsgBox("now indexing with: " & idxvalue)
Dim oErrorOccurred = windream_index.RunIndexing(WMdok, arrIndex, arrValue, _profObjekttyp) Dim oErrorOccurred = windream_index.RunIndexing(WMdok, arrIndex, arrValue, _profObjekttyp)
' 07.01.2019: Weitere Jobs bei Fehler in RunIndexing überspringen ' 07.01.2019: Weitere Jobs bei Fehler in RunIndexing überspringen
@@ -644,27 +643,35 @@ Public Class clsProfil
Next Next
Case "Send InfoMail with WM-Search".ToUpper Case "Send InfoMail with WM-Search".ToUpper
Logger.Info("Working on CASE Send InfoMail with WM-Search.... ") Logger.Info("Working on CASE Send InfoMail with WM-Search.... ")
Dim oWMResults As WMObjects = windream.GetSearchDocuments(DR_PR_JB.Item("STRING5")) 'Dim oWMResults As WMObjects = windream.GetSearchDocuments(DR_PR_JB.Item("STRING5"))
If oWMResults Is Nothing Then 'If oWMResults Is Nothing Then
Logger.Warn("windreamSucheErgebnisse is nothing ( Send InfoMail with WM-Search)!", True, "clsProfil.Profil_Durchlauf") ' Logger.Warn("windreamSucheErgebnisse is nothing ( Send InfoMail with WM-Search)!", True, "clsProfil.Profil_Durchlauf")
Return False ' Return False
End If 'End If
If oWMResults.Count > 0 Then Try
If _JobWork.New_Mail_with_attachment(DR_PR_JB.Item("STRING1"), DR_PR_JB.Item("STRING2"), DR_PR_JB.Item("STRING3"), DR_PR_JB.Item("STRING4"), clsCURRENT.DT_TBDD_EMAIL, DR_PR_JB.Item("STRING5")) = True Then If windreamSucheErgebnisse.Count > 0 Then
FileJobSuccessful = True Logger.Debug("windreamSucheErgebnisse.Count > 0 .... ")
If DT_PROFIL_FILE_JOB.Rows.Count > 0 Then If _JobWork.New_Mail_with_attachment(DR_PR_JB.Item("STRING1"), DR_PR_JB.Item("STRING2"), DR_PR_JB.Item("STRING3"), DR_PR_JB.Item("STRING4"), clsCURRENT.DT_TBDD_EMAIL, DR_PR_JB.Item("STRING5")) = True Then
For Each DR_PR_FILE_JOB As DataRow In DT_PROFIL_FILE_JOB.Rows FileJobSuccessful = True
For Each oWMDoc As WMObject In oWMResults 'If DT_PROFIL_FILE_JOB.Rows.Count > 0 Then
_dateiverarbeitung.Check_File_job(oWMDoc, DR_PR_FILE_JOB.Item("TYP").ToString.ToLower, DR_PR_FILE_JOB.Item("STRING1").ToString, DR_PR_FILE_JOB.Item("STRING2").ToString, _profObjekttyp, windream_index) ' For Each DR_PR_FILE_JOB As DataRow In DT_PROFIL_FILE_JOB.Rows
Next ' For Each oWMDoc As WMObject In oWMResults
' _dateiverarbeitung.Check_File_job(oWMDoc, DR_PR_FILE_JOB.Item("TYP").ToString.ToLower, DR_PR_FILE_JOB.Item("STRING1").ToString, DR_PR_FILE_JOB.Item("STRING2").ToString, _profObjekttyp, windream_index)
' Next
' Next
'End If
Next
End If End If
Else
Logger.Info("Attention: Send InfoMail with WM-Search - windreamSucheErgebnisse.Count = 0")
FileJobSuccessful = False
End If End If
Else Catch ex As Exception
Logger.Info("Send InfoMail with WM-Search - oWMResults.Count = 0") Logger.Warn($"Unexpected Error in Case [Send InfoMail with WM-Search] Error: [{ex.Message}]")
End If FileJobSuccessful = False
End Try
End Select End Select
If FileJobSuccessful = True Then If FileJobSuccessful = True Then

View File

@@ -286,7 +286,7 @@ Public Class clsWindream_Index
'If indexname = "Tournr" Then 'If indexname = "Tournr" Then
'End If 'End If
Logger.Info("Indexierung von Index '" & indexname & "'") Logger.Debug("Indexierung von Index '" & indexname & "'")
Dim value = aValues(i) Dim value = aValues(i)
Dim convertValue Dim convertValue
@@ -562,7 +562,7 @@ Public Class clsWindream_Index
End If End If
'Jetzt die Nachindexierung für Vektor-Felder 'Jetzt die Nachindexierung für Vektor-Felder
oDocument.SetVariableValue(aName, myArray) oDocument.SetVariableValue(aName, myArray)
Logger.Info("'SetVariableValue' für VEKTOR erfolgreich") Logger.Debug("'SetVariableValue' für VEKTOR erfolgreich")
End If End If
Else Else
Logger.Debug("Array der Indexwerte ist leer/Nothing - Keine Nachindexierung") Logger.Debug("Array der Indexwerte ist leer/Nothing - Keine Nachindexierung")

View File

@@ -6,9 +6,6 @@
</sectionGroup> </sectionGroup>
<section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" /> <section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 --> <!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
<sectionGroup name="userSettings" type="System.Configuration.UserSettingsGroup, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" >
<section name="DDWDResultHandler.My.MySettings" type="System.Configuration.ClientSettingsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false" />
</sectionGroup>
</configSections> </configSections>
<connectionStrings /> <connectionStrings />
<startup> <startup>
@@ -17,10 +14,13 @@
<applicationSettings> <applicationSettings>
<DDWDResultHandler.My.MySettings> <DDWDResultHandler.My.MySettings>
<setting name="SQLSERVER_CS_RH" serializeAs="String"> <setting name="SQLSERVER_CS_RH" serializeAs="String">
<value>Data Source=172.24.12.41\tests;Initial Catalog=DD_ECM_RENOLIT;Persist Security Info=True;User ID=sa;Password=dd</value> <value>Data Source=SDD-VMP04-SQL17\DD_DEVELOP01;Initial Catalog=DD_ECM_TEST;Persist Security Info=True;User ID=sa;Password=dd</value>
</setting> </setting>
<setting name="SQLSERVER_CS_PMRefresh" serializeAs="String"> <setting name="SQLSERVER_CS_PMRefresh" serializeAs="String">
<value /> <value>Data Source=SDD-VMP04-SQL17\DD_DEVELOP01;Initial Catalog=DD_ECM_TEST;Persist Security Info=True;User ID=sa;Password=dd</value>
</setting>
<setting name="PMREFRESH_INTERVALL" serializeAs="String">
<value>2</value>
</setting> </setting>
</DDWDResultHandler.My.MySettings> </DDWDResultHandler.My.MySettings>
</applicationSettings> </applicationSettings>
@@ -43,11 +43,4 @@
</dependentAssembly> </dependentAssembly>
</assemblyBinding> </assemblyBinding>
</runtime> </runtime>
<userSettings>
<DDWDResultHandler.My.MySettings>
<setting name="PMREFRESH_INTERVALL" serializeAs="String">
<value />
</setting>
</DDWDResultHandler.My.MySettings>
</userSettings>
</configuration> </configuration>

View File

@@ -96,7 +96,6 @@ Public Class DDWDResultHandler
If My.Settings.SQLSERVER_CS_RH <> "" Then If My.Settings.SQLSERVER_CS_RH <> "" Then
Logger.Info("Thread ResultHandler will now be started for initial Run..") Logger.Info("Thread ResultHandler will now be started for initial Run..")
threadResultHandler.RunWorkerAsync() threadResultHandler.RunWorkerAsync()
Logger.Info("Thread PM Refresh will be started after 2mins for initial Run..")
End If End If
End If End If
@@ -185,7 +184,7 @@ Public Class DDWDResultHandler
End If End If
Next Next
Else Else
Logger.Info("Keine aktiven Profile WMResulthandler vorhanden") Logger.Info("Keine aktiven Profile für WMResulthandler vorhanden")
notcompleted = True notcompleted = True
End If End If
'Try 'Try
@@ -205,7 +204,7 @@ Public Class DDWDResultHandler
threadPMRefresh.RunWorkerAsync() threadPMRefresh.RunWorkerAsync()
End If End If
Else Else
Logger.Warn("clsDatabase konnte nicht initialisiert werden!") Logger.Warn($"clsDatabase konnte nicht initialisiert werden! {My.Settings.SQLSERVER_CS_RH}")
notcompleted = True notcompleted = True
End If End If
Else Else

View File

@@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
' übernehmen, indem Sie "*" eingeben: ' übernehmen, indem Sie "*" eingeben:
' <Assembly: AssemblyVersion("1.0.*")> ' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("1.0.0.1")> <Assembly: AssemblyVersion("2.0.0.0")>
<Assembly: AssemblyFileVersion("1.0.0.0")> <Assembly: AssemblyFileVersion("1.0.0.0")>

View File

@@ -15,7 +15,7 @@ Option Explicit On
Namespace My Namespace My
<Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute(), _ <Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "15.7.0.0"), _ Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.4.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _ Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
Partial Friend NotInheritable Class MySettings Partial Friend NotInheritable Class MySettings
Inherits Global.System.Configuration.ApplicationSettingsBase Inherits Global.System.Configuration.ApplicationSettingsBase
@@ -56,8 +56,8 @@ Namespace My
<Global.System.Configuration.ApplicationScopedSettingAttribute(), _ <Global.System.Configuration.ApplicationScopedSettingAttribute(), _
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _ Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.Configuration.DefaultSettingValueAttribute("Data Source=172.24.12.41\tests;Initial Catalog=DD_ECM_RENOLIT;Persist Security In"& _ Global.System.Configuration.DefaultSettingValueAttribute("Data Source=SDD-VMP04-SQL17\DD_DEVELOP01;Initial Catalog=DD_ECM_TEST;Persist Secu"& _
"fo=True;User ID=sa;Password=dd")> _ "rity Info=True;User ID=sa;Password=dd")> _
Public ReadOnly Property SQLSERVER_CS_RH() As String Public ReadOnly Property SQLSERVER_CS_RH() As String
Get Get
Return CType(Me("SQLSERVER_CS_RH"),String) Return CType(Me("SQLSERVER_CS_RH"),String)
@@ -66,23 +66,21 @@ Namespace My
<Global.System.Configuration.ApplicationScopedSettingAttribute(), _ <Global.System.Configuration.ApplicationScopedSettingAttribute(), _
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _ Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.Configuration.DefaultSettingValueAttribute("")> _ Global.System.Configuration.DefaultSettingValueAttribute("Data Source=SDD-VMP04-SQL17\DD_DEVELOP01;Initial Catalog=DD_ECM_TEST;Persist Secu"& _
"rity Info=True;User ID=sa;Password=dd")> _
Public ReadOnly Property SQLSERVER_CS_PMRefresh() As String Public ReadOnly Property SQLSERVER_CS_PMRefresh() As String
Get Get
Return CType(Me("SQLSERVER_CS_PMRefresh"),String) Return CType(Me("SQLSERVER_CS_PMRefresh"),String)
End Get End Get
End Property End Property
<Global.System.Configuration.UserScopedSettingAttribute(), _ <Global.System.Configuration.ApplicationScopedSettingAttribute(), _
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _ Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.Configuration.DefaultSettingValueAttribute("")> _ Global.System.Configuration.DefaultSettingValueAttribute("2")> _
Public Property PMREFRESH_INTERVALL() As String Public ReadOnly Property PMREFRESH_INTERVALL() As Integer
Get Get
Return CType(Me("PMREFRESH_INTERVALL"),String) Return CType(Me("PMREFRESH_INTERVALL"),Integer)
End Get End Get
Set
Me("PMREFRESH_INTERVALL") = value
End Set
End Property End Property
End Class End Class
End Namespace End Namespace

View File

@@ -3,10 +3,13 @@
<Profiles /> <Profiles />
<Settings> <Settings>
<Setting Name="SQLSERVER_CS_RH" Type="System.String" Scope="Application"> <Setting Name="SQLSERVER_CS_RH" Type="System.String" Scope="Application">
<Value Profile="(Default)">Data Source=172.24.12.41\tests;Initial Catalog=DD_ECM_RENOLIT;Persist Security Info=True;User ID=sa;Password=dd</Value> <Value Profile="(Default)">Data Source=SDD-VMP04-SQL17\DD_DEVELOP01;Initial Catalog=DD_ECM_TEST;Persist Security Info=True;User ID=sa;Password=dd</Value>
</Setting> </Setting>
<Setting Name="SQLSERVER_CS_PMRefresh" Type="System.String" Scope="Application"> <Setting Name="SQLSERVER_CS_PMRefresh" Type="System.String" Scope="Application">
<Value Profile="(Default)" /> <Value Profile="(Default)">Data Source=SDD-VMP04-SQL17\DD_DEVELOP01;Initial Catalog=DD_ECM_TEST;Persist Security Info=True;User ID=sa;Password=dd</Value>
</Setting>
<Setting Name="PMREFRESH_INTERVALL" Type="System.Int32" Scope="Application">
<Value Profile="(Default)">2</Value>
</Setting> </Setting>
</Settings> </Settings>
</SettingsFile> </SettingsFile>

View File

@@ -75,6 +75,8 @@ Public Class clsPMRefresh
Return True Return True
Else Else
Logger.Info($"No run of PMRefresh as hour is not in timespan ({CInt(Now.Hour)} >= {oMinHour} And {CInt(Now.Hour)} < {oMaxHour})") Logger.Info($"No run of PMRefresh as hour is not in timespan ({CInt(Now.Hour)} >= {oMinHour} And {CInt(Now.Hour)} < {oMaxHour})")
Logger.Info($"Check TBPM_KONFIGURATION Column SERVICE_SCHEDULE")
End If End If
Else Else
Logger.Info($"No run of PMRefresh as today Is Not configured as RUN") Logger.Info($"No run of PMRefresh as today Is Not configured as RUN")
@@ -97,6 +99,68 @@ Public Class clsPMRefresh
End Try End Try
End Function End Function
Public Function GetSearchDocumentsDTviaSQL(ByVal pSQLCommand As String) As DataTable
Dim dtresult As New DataTable
dtresult.Columns.Add("DOC_ID", GetType(Integer))
dtresult.Columns.Add("PATH", GetType(String))
dtresult.Columns.Add("CREATED", GetType(String))
Try
Dim oSQLRESULT As DataTable = _database.Return_Datatable(pSQLCommand)
If IsNothing(oSQLRESULT) Then
Return dtresult
End If
'If returnDT = True Then
If oSQLRESULT.Rows.Count > 0 Then
For Each oDocRow As DataRow In oSQLRESULT.Rows
Dim oDOC_ID As Int64
Try
oDOC_ID = oDocRow.Item("IDB_OBJ_ID")
Catch ex As Exception
Try
oDOC_ID = oDocRow.Item("DocID")
Catch ex1 As Exception
Logger.Warn("Could not get DocID-Column: " & ex.Message)
Return dtresult
End Try
End Try
Dim oCreated
Try
oCreated = oDocRow.Item("ADDED_WHEN")
Catch ex As Exception
Try
oCreated = oDocRow.Item("AddedWhen")
Catch ex1 As Exception
Logger.Warn($"(GetSearchDocumentsDTviaSQL)Could not get AddedWhen-Column: [{ex.Message}] - SQL-Command: [{pSQLCommand}]")
Return dtresult
End Try
End Try
Dim oPath As String
Try
oPath = oDocRow.Item("DocRelativePath")
Catch ex As Exception
Try
oPath = oDocRow.Item("FULL_FILENAME")
Catch ex1 As Exception
Logger.Warn($"(GetSearchDocumentsDTviaSQL)Could not get FULL_FILENAME-Column: [{ex.Message}] - SQL-Command: [{pSQLCommand}]")
Return dtresult
End Try
End Try
Logger.Debug($"Adding DocInfo {oDOC_ID.ToString}|{oPath}|{oCreated}")
dtresult.Rows.Add(oDOC_ID, oPath, oCreated)
Next
dtresult.AcceptChanges()
End If
Return dtresult
Catch ex As Exception
Logger.Error(ex)
Logger.Warn($"Error Getting Docs via SLQ ({pSQLCommand})")
Return dtresult
End Try
End Function
Public Function Refresh_Data() Public Function Refresh_Data()
Dim oStep As String Dim oStep As String
Try Try
@@ -134,7 +198,13 @@ Public Class clsPMRefresh
'---------------------- Die Dateien auslesen ------------------------ '---------------------- Die Dateien auslesen ------------------------
Dim oDTWM_Results As DataTable Dim oDTWM_Results As DataTable
oStep = "4c" oStep = "4c"
oDTWM_Results = _windream.GetSearchDocumentsDT(WD_Search, oConfigIDXName_DocID, oConfigIDXName_Created, True) If WD_Search.Contains("wdf") Or WD_Search.Contains("wdfx") Then
oDTWM_Results = _windream.GetSearchDocumentsDT(WD_Search, oConfigIDXName_DocID, oConfigIDXName_Created, True)
Else
Logger.Debug("Search via SQL")
oDTWM_Results = GetSearchDocumentsDTviaSQL(WD_Search)
End If
oStep = "4d" oStep = "4d"
Dim oDocCount As Integer = 0 Dim oDocCount As Integer = 0
If IsNothing(oDTWM_Results) Then If IsNothing(oDTWM_Results) Then

View File

@@ -8,7 +8,7 @@
<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 --> <!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
</configSections> </configSections>
<connectionStrings> <connectionStrings>
<add name="ResultHandler_Konfig.My.MySettings.SQLSERVER_CS" connectionString="Data Source=172.24.12.41\tests;Initial Catalog=DD_ECM_RENOLIT;Persist Security Info=True;User ID=sa;Password=dd" <add name="ResultHandler_Konfig.My.MySettings.SQLSERVER_CS" connectionString="Data Source=SDD-VMP04-SQL17\DD_DEVELOP01;Initial Catalog=DD_ECM_TEST;Persist Security Info=True;User ID=sa;Password=dd"
providerName="System.Data.SqlClient" /> providerName="System.Data.SqlClient" />
</connectionStrings> </connectionStrings>
<startup> <startup>

View File

@@ -15,7 +15,7 @@ Option Explicit On
Namespace My Namespace My
<Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute(), _ <Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "15.7.0.0"), _ Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.4.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _ Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
Partial Friend NotInheritable Class MySettings Partial Friend NotInheritable Class MySettings
Inherits Global.System.Configuration.ApplicationSettingsBase Inherits Global.System.Configuration.ApplicationSettingsBase
@@ -57,8 +57,8 @@ Namespace My
<Global.System.Configuration.ApplicationScopedSettingAttribute(), _ <Global.System.Configuration.ApplicationScopedSettingAttribute(), _
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _ Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.Configuration.SpecialSettingAttribute(Global.System.Configuration.SpecialSetting.ConnectionString), _ Global.System.Configuration.SpecialSettingAttribute(Global.System.Configuration.SpecialSetting.ConnectionString), _
Global.System.Configuration.DefaultSettingValueAttribute("Data Source=172.24.12.41\tests;Initial Catalog=DD_ECM_RENOLIT;Persist Security In"& _ Global.System.Configuration.DefaultSettingValueAttribute("Data Source=SDD-VMP04-SQL17\DD_DEVELOP01;Initial Catalog=DD_ECM_TEST;Persist Secu"& _
"fo=True;User ID=sa;Password=dd")> _ "rity Info=True;User ID=sa;Password=dd")> _
Public ReadOnly Property SQLSERVER_CS() As String Public ReadOnly Property SQLSERVER_CS() As String
Get Get
Return CType(Me("SQLSERVER_CS"),String) Return CType(Me("SQLSERVER_CS"),String)

View File

@@ -5,10 +5,10 @@
<Setting Name="SQLSERVER_CS" Type="(Connection string)" Scope="Application"> <Setting Name="SQLSERVER_CS" Type="(Connection string)" Scope="Application">
<DesignTimeValue Profile="(Default)">&lt;?xml version="1.0" encoding="utf-16"?&gt; <DesignTimeValue Profile="(Default)">&lt;?xml version="1.0" encoding="utf-16"?&gt;
&lt;SerializableConnectionString xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"&gt; &lt;SerializableConnectionString xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"&gt;
&lt;ConnectionString&gt;Data Source=172.24.12.41\tests;Initial Catalog=DD_ECM_RENOLIT;Persist Security Info=True;User ID=sa;Password=dd&lt;/ConnectionString&gt; &lt;ConnectionString&gt;Data Source=SDD-VMP04-SQL17\DD_DEVELOP01;Initial Catalog=DD_ECM_TEST;Persist Security Info=True;User ID=sa;Password=dd&lt;/ConnectionString&gt;
&lt;ProviderName&gt;System.Data.SqlClient&lt;/ProviderName&gt; &lt;ProviderName&gt;System.Data.SqlClient&lt;/ProviderName&gt;
&lt;/SerializableConnectionString&gt;</DesignTimeValue> &lt;/SerializableConnectionString&gt;</DesignTimeValue>
<Value Profile="(Default)">Data Source=172.24.12.41\tests;Initial Catalog=DD_ECM_RENOLIT;Persist Security Info=True;User ID=sa;Password=dd</Value> <Value Profile="(Default)">Data Source=SDD-VMP04-SQL17\DD_DEVELOP01;Initial Catalog=DD_ECM_TEST;Persist Security Info=True;User ID=sa;Password=dd</Value>
</Setting> </Setting>
<Setting Name="BNSAPI_HOST" Type="System.String" Scope="User"> <Setting Name="BNSAPI_HOST" Type="System.String" Scope="User">
<Value Profile="(Default)" /> <Value Profile="(Default)" />

View File

@@ -1 +1 @@
DevExpress.XtraGrid.GridControl, DevExpress.XtraGrid.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a DevExpress.XtraGrid.GridControl, DevExpress.XtraGrid.v18.1, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a

View File

@@ -54,17 +54,24 @@
<ApplicationIcon>ico638.ico</ApplicationIcon> <ApplicationIcon>ico638.ico</ApplicationIcon>
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="DevExpress.Data.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" /> <Reference Include="DevExpress.Data.v18.1, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.Printing.v15.2.Core, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" /> <Reference Include="DevExpress.Pdf.v18.1.Core, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.Sparkline.v15.2.Core, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" /> <Reference Include="DevExpress.Office.v18.1.Core, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.Utils.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" /> <Reference Include="DevExpress.RichEdit.v18.1.Core, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.XtraEditors.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" /> <Reference Include="DevExpress.RichEdit.v18.1.Export, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.XtraGrid.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL" /> <Reference Include="DevExpress.Printing.v18.1.Core, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.XtraLayout.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" /> <Reference Include="DevExpress.Sparkline.v18.1.Core, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.XtraPrinting.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" /> <Reference Include="DevExpress.Utils.v18.1, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.XtraEditors.v18.1, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.XtraGrid.v18.1, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL" />
<Reference Include="DevExpress.XtraLayout.v18.1, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.XtraPrinting.v18.1, Version=18.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DigitalData.Modules.Logging"> <Reference Include="DigitalData.Modules.Logging">
<HintPath>..\..\..\DDMonorepo\Modules.Logging\bin\Debug\DigitalData.Modules.Logging.dll</HintPath> <HintPath>..\..\..\DDMonorepo\Modules.Logging\bin\Debug\DigitalData.Modules.Logging.dll</HintPath>
</Reference> </Reference>
<Reference Include="DigitalData.Modules.Messaging">
<HintPath>..\..\..\DDMonorepo\Message\bin\Debug\DigitalData.Modules.Messaging.dll</HintPath>
</Reference>
<Reference Include="EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL"> <Reference Include="EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL">
<HintPath>..\packages\EntityFramework.6.2.0\lib\net45\EntityFramework.dll</HintPath> <HintPath>..\packages\EntityFramework.6.2.0\lib\net45\EntityFramework.dll</HintPath>
</Reference> </Reference>

View File

@@ -0,0 +1,235 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{85F6D07F-4C83-41C6-AEF1-66F228C13C25}</ProjectGuid>
<OutputType>WinExe</OutputType>
<StartupObject>ResultHandler_Konfig.My.MyApplication</StartupObject>
<RootNamespace>ResultHandler_Konfig</RootNamespace>
<AssemblyName>ResultHandler_Konfig</AssemblyName>
<FileAlignment>512</FileAlignment>
<MyType>WindowsForms</MyType>
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<TargetFrameworkProfile />
<NuGetPackageImportStamp>
</NuGetPackageImportStamp>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<DefineDebug>true</DefineDebug>
<DefineTrace>true</DefineTrace>
<OutputPath>bin\Debug\</OutputPath>
<DocumentationFile>ResultHandler_Konfig.xml</DocumentationFile>
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<DefineDebug>false</DefineDebug>
<DefineTrace>true</DefineTrace>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DocumentationFile>ResultHandler_Konfig.xml</DocumentationFile>
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
</PropertyGroup>
<PropertyGroup>
<OptionExplicit>On</OptionExplicit>
</PropertyGroup>
<PropertyGroup>
<OptionCompare>Binary</OptionCompare>
</PropertyGroup>
<PropertyGroup>
<OptionStrict>Off</OptionStrict>
</PropertyGroup>
<PropertyGroup>
<OptionInfer>On</OptionInfer>
</PropertyGroup>
<PropertyGroup>
<ApplicationIcon>ico638.ico</ApplicationIcon>
</PropertyGroup>
<ItemGroup>
<Reference Include="DevExpress.Data.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.Printing.v15.2.Core, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.Sparkline.v15.2.Core, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.Utils.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.XtraEditors.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.XtraGrid.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a, processorArchitecture=MSIL" />
<Reference Include="DevExpress.XtraLayout.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DevExpress.XtraPrinting.v15.2, Version=15.2.16.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<Reference Include="DigitalData.Modules.Logging">
<HintPath>..\..\..\DDMonorepo\Modules.Logging\bin\Debug\DigitalData.Modules.Logging.dll</HintPath>
</Reference>
<Reference Include="EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL">
<HintPath>..\packages\EntityFramework.6.2.0\lib\net45\EntityFramework.dll</HintPath>
</Reference>
<Reference Include="EntityFramework.SqlServer, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL">
<HintPath>..\packages\EntityFramework.6.2.0\lib\net45\EntityFramework.SqlServer.dll</HintPath>
</Reference>
<Reference Include="Interop.WINDREAMLib">
<HintPath>P:\Visual Studio Projekte\Bibliotheken\windream\Interop.WINDREAMLib.dll</HintPath>
<EmbedInteropTypes>False</EmbedInteropTypes>
</Reference>
<Reference Include="Interop.WMOBRWSLib">
<HintPath>P:\Visual Studio Projekte\Bibliotheken\windream\Interop.WMOBRWSLib.dll</HintPath>
<EmbedInteropTypes>True</EmbedInteropTypes>
</Reference>
<Reference Include="Interop.WMOSRCHLib">
<HintPath>P:\Visual Studio Projekte\Bibliotheken\windream\Interop.WMOSRCHLib.dll</HintPath>
<EmbedInteropTypes>True</EmbedInteropTypes>
</Reference>
<Reference Include="Interop.WMOTOOLLib">
<HintPath>P:\Visual Studio Projekte\Bibliotheken\windream\Interop.WMOTOOLLib.dll</HintPath>
<EmbedInteropTypes>True</EmbedInteropTypes>
</Reference>
<Reference Include="Microsoft.CSharp" />
<Reference Include="Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\packages\Newtonsoft.Json.10.0.3\lib\net45\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="NLog, Version=4.0.0.0, Culture=neutral, PublicKeyToken=5120e14c03d0593c, processorArchitecture=MSIL">
<HintPath>..\packages\NLog.4.5.8\lib\net45\NLog.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.ComponentModel.DataAnnotations" />
<Reference Include="System.Configuration" />
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.IO.Compression" />
<Reference Include="System.Runtime.Serialization" />
<Reference Include="System.ServiceModel" />
<Reference Include="System.ServiceProcess" />
<Reference Include="System.Transactions" />
<Reference Include="System.Web.Services" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
</ItemGroup>
<ItemGroup>
<Import Include="Microsoft.VisualBasic" />
<Import Include="System" />
<Import Include="System.Collections" />
<Import Include="System.Collections.Generic" />
<Import Include="System.Data" />
<Import Include="System.Drawing" />
<Import Include="System.Diagnostics" />
<Import Include="System.Windows.Forms" />
<Import Include="System.Linq" />
<Import Include="System.Xml.Linq" />
<Import Include="System.Threading.Tasks" />
</ItemGroup>
<ItemGroup>
<Compile Include="frmMain.vb">
<SubType>Form</SubType>
</Compile>
<Compile Include="frmMain.Designer.vb">
<DependentUpon>frmMain.vb</DependentUpon>
<SubType>Form</SubType>
</Compile>
<Compile Include="My Project\AssemblyInfo.vb" />
<Compile Include="My Project\Application.Designer.vb">
<AutoGen>True</AutoGen>
<DependentUpon>Application.myapp</DependentUpon>
</Compile>
<Compile Include="My Project\Resources.Designer.vb">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<Compile Include="My Project\Settings.Designer.vb">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
<Compile Include="MyDataset.Designer.vb">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>MyDataset.xsd</DependentUpon>
</Compile>
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="frmMain.resx">
<DependentUpon>frmMain.vb</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="My Project\licenses.licx" />
<EmbeddedResource Include="My Project\Resources.resx">
<Generator>VbMyResourcesResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.vb</LastGenOutput>
<CustomToolNamespace>My.Resources</CustomToolNamespace>
<SubType>Designer</SubType>
</EmbeddedResource>
</ItemGroup>
<ItemGroup>
<None Include="My Project\Application.myapp">
<Generator>MyApplicationCodeGenerator</Generator>
<LastGenOutput>Application.Designer.vb</LastGenOutput>
</None>
<None Include="My Project\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<CustomToolNamespace>My</CustomToolNamespace>
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
</None>
<None Include="App.config" />
</ItemGroup>
<ItemGroup>
<None Include="MyDataset.xsc">
<DependentUpon>MyDataset.xsd</DependentUpon>
</None>
<None Include="MyDataset.xsd">
<SubType>Designer</SubType>
<Generator>MSDataSetGenerator</Generator>
<LastGenOutput>MyDataset.Designer.vb</LastGenOutput>
</None>
<None Include="MyDataset.xss">
<DependentUpon>MyDataset.xsd</DependentUpon>
</None>
<None Include="packages.config" />
<None Include="Resources\flag_green.png" />
</ItemGroup>
<ItemGroup>
<None Include="Resources\arrow_refresh.png" />
</ItemGroup>
<ItemGroup>
<None Include="Resources\arrow_switch.png" />
</ItemGroup>
<ItemGroup>
<None Include="Resources\save.bmp" />
</ItemGroup>
<ItemGroup>
<None Include="Resources\add.png" />
</ItemGroup>
<ItemGroup>
<Content Include="bin\Debug\x64\SQLite.Interop.dll" />
<Content Include="ico638.ico" />
<None Include="Resources\refresh_16xMD.png" />
<None Include="Resources\folder_Open_16xMD.png" />
<None Include="Resources\book_open.png" />
<None Include="Resources\key_go.png" />
<None Include="Resources\email_go.png" />
</ItemGroup>
<ItemGroup>
<WCFMetadata Include="Connected Services\" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\ClassWMResulthandler\DD_WMResulthandler.vbproj">
<Project>{b3190aec-8dc4-4822-9609-54df5b976262}</Project>
<Name>DD_WMResulthandler</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>

View File

@@ -238,7 +238,7 @@ Partial Class frmMain
Me.Button4 = New System.Windows.Forms.Button() Me.Button4 = New System.Windows.Forms.Button()
Me.ContextMenuStrip1 = New System.Windows.Forms.ContextMenuStrip(Me.components) Me.ContextMenuStrip1 = New System.Windows.Forms.ContextMenuStrip(Me.components)
Me.EncryptToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.EncryptToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem()
Me.txtTestmail = New System.Windows.Forms.TextBox() Me.txtTestmailTo = New System.Windows.Forms.TextBox()
Me.Label1 = New System.Windows.Forms.Label() Me.Label1 = New System.Windows.Forms.Label()
Me.btnsendtestmail = New System.Windows.Forms.Button() Me.btnsendtestmail = New System.Windows.Forms.Button()
Me.GUIDTextBox1 = New System.Windows.Forms.TextBox() Me.GUIDTextBox1 = New System.Windows.Forms.TextBox()
@@ -2372,7 +2372,7 @@ Partial Class frmMain
Me.TabPage4.Controls.Add(Label5) Me.TabPage4.Controls.Add(Label5)
Me.TabPage4.Controls.Add(Me.txtnewpasswort) Me.TabPage4.Controls.Add(Me.txtnewpasswort)
Me.TabPage4.Controls.Add(Me.Button4) Me.TabPage4.Controls.Add(Me.Button4)
Me.TabPage4.Controls.Add(Me.txtTestmail) Me.TabPage4.Controls.Add(Me.txtTestmailTo)
Me.TabPage4.Controls.Add(Me.Label1) Me.TabPage4.Controls.Add(Me.Label1)
Me.TabPage4.Controls.Add(Me.btnsendtestmail) Me.TabPage4.Controls.Add(Me.btnsendtestmail)
Me.TabPage4.Controls.Add(GUIDLabel3) Me.TabPage4.Controls.Add(GUIDLabel3)
@@ -2490,14 +2490,14 @@ Partial Class frmMain
Me.EncryptToolStripMenuItem.Size = New System.Drawing.Size(114, 22) Me.EncryptToolStripMenuItem.Size = New System.Drawing.Size(114, 22)
Me.EncryptToolStripMenuItem.Text = "encrypt" Me.EncryptToolStripMenuItem.Text = "encrypt"
' '
'txtTestmail 'txtTestmailTo
' '
Me.txtTestmail.DataBindings.Add(New System.Windows.Forms.Binding("Text", Global.ResultHandler_Konfig.My.MySettings.Default, "EmailTestReceipiant", True, System.Windows.Forms.DataSourceUpdateMode.OnPropertyChanged)) Me.txtTestmailTo.DataBindings.Add(New System.Windows.Forms.Binding("Text", Global.ResultHandler_Konfig.My.MySettings.Default, "EmailTestReceipiant", True, System.Windows.Forms.DataSourceUpdateMode.OnPropertyChanged))
Me.txtTestmail.Location = New System.Drawing.Point(78, 347) Me.txtTestmailTo.Location = New System.Drawing.Point(78, 347)
Me.txtTestmail.Name = "txtTestmail" Me.txtTestmailTo.Name = "txtTestmailTo"
Me.txtTestmail.Size = New System.Drawing.Size(311, 22) Me.txtTestmailTo.Size = New System.Drawing.Size(311, 22)
Me.txtTestmail.TabIndex = 29 Me.txtTestmailTo.TabIndex = 29
Me.txtTestmail.Text = Global.ResultHandler_Konfig.My.MySettings.Default.EmailTestReceipiant Me.txtTestmailTo.Text = Global.ResultHandler_Konfig.My.MySettings.Default.EmailTestReceipiant
' '
'Label1 'Label1
' '
@@ -3027,7 +3027,7 @@ Partial Class frmMain
Friend WithEvents CHANGED_WHOTextBox As TextBox Friend WithEvents CHANGED_WHOTextBox As TextBox
Friend WithEvents CHANGED_WHENTextBox As TextBox Friend WithEvents CHANGED_WHENTextBox As TextBox
Friend WithEvents btnsendtestmail As Button Friend WithEvents btnsendtestmail As Button
Friend WithEvents txtTestmail As TextBox Friend WithEvents txtTestmailTo As TextBox
Friend WithEvents Label1 As Label Friend WithEvents Label1 As Label
Friend WithEvents Button4 As Button Friend WithEvents Button4 As Button
Friend WithEvents txtnewpasswort As TextBox Friend WithEvents txtnewpasswort As TextBox

View File

@@ -260,7 +260,7 @@
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0 LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAAI ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAAI
DAAAAk1TRnQBSQFMAgEBAwEAAXgBAwF4AQMBEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo DAAAAk1TRnQBSQFMAgEBAwEAAYABAwGAAQMBEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
AwABQAMAARADAAEBAQABCAYAAQQYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA AwABQAMAARADAAEBAQABCAYAAQQYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5 AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA

View File

@@ -1,5 +1,6 @@
Imports System.ServiceProcess Imports System.ServiceProcess
Imports DigitalData.Modules.Logging Imports DigitalData.Modules.Logging
Imports DigitalData.Modules.Messaging
Imports DD_WMResulthandler Imports DD_WMResulthandler
Imports System.Net.Mail Imports System.Net.Mail
Imports System.Net Imports System.Net
@@ -8,7 +9,6 @@ Public Class frmMain
Private _windream As clsWindream_allgemein Private _windream As clsWindream_allgemein
Private _database As clsDatabase Private _database As clsDatabase
Private _profil As clsProfil Private _profil As clsProfil
Private _email As clsEmail
Dim MyLogger As LogConfig Dim MyLogger As LogConfig
Dim Logger As Logger Dim Logger As Logger
Dim switchRecord As Boolean = True Dim switchRecord As Boolean = True
@@ -34,7 +34,6 @@ Public Class frmMain
Logger = MyLogger.GetLogger() Logger = MyLogger.GetLogger()
Load_Constring() Load_Constring()
_database = New clsDatabase(MyLogger) _database = New clsDatabase(MyLogger)
_email = New clsEmail(MyLogger)
Logger.Info("Konfig started: " & Now.ToString) Logger.Info("Konfig started: " & Now.ToString)
Try Try
' Windream instanziieren ' Windream instanziieren
@@ -843,7 +842,7 @@ Public Class frmMain
mymesssage.From = New MailAddress(EMAIL_FROMTextBox.Text) mymesssage.From = New MailAddress(EMAIL_FROMTextBox.Text)
mymesssage.Subject = "TestSubject from RAW Method" mymesssage.Subject = "TestSubject from RAW Method"
mymesssage.To.Add(New MailAddress(txtTestmail.Text)) mymesssage.To.Add(New MailAddress(txtTestmailTo.Text))
If txtAttachment.Text <> String.Empty Then If txtAttachment.Text <> String.Empty Then
Dim oAttment As String = txtAttachment.Text.Replace("W:\", "\\windream\objects\") Dim oAttment As String = txtAttachment.Text.Replace("W:\", "\\windream\objects\")
@@ -869,22 +868,21 @@ Public Class frmMain
End Sub End Sub
Private Sub btnsendtestmail_Click(sender As Object, e As EventArgs) Handles btnsendtestmail.Click Private Sub btnsendtestmail_Click(sender As Object, e As EventArgs) Handles btnsendtestmail.Click
Dim _ss2email As New Email(MyLogger)
If txtTestmailTo.Text <> String.Empty Then
If txtTestmail.Text <> String.Empty Then
My.Settings.Save() My.Settings.Save()
Dim wrapper As New clsEncryption("!35452didalog=") Dim wrapper As New clsEncryption("!35452didalog=")
Dim PWPlain = wrapper.DecryptData(EMAIL_PWTextBox.Text) Dim PWPlain = wrapper.DecryptData(EMAIL_PWTextBox.Text)
If _ss2email.NewEmail(txtTestmailTo.Text, "Testmail from GUI WMResultHandler", "This is the body (text will be replaced within profile)", EMAIL_FROMTextBox.Text, EMAIL_SMTPTextBox.Text,
PORTTextBox.Text, EMAIL_USERTextBox.Text, PWPlain, AUTH_TYPEComboBox.Text, "GUI WMRH - Test") = True Then
If _email.Email_Send("Testmail from GUI WMResultHandler", "This is the body (text will be replaced within profile)", txtTestmail.Text,
EMAIL_FROMTextBox.Text, EMAIL_SMTPTextBox.Text, PORTTextBox.Text, EMAIL_USERTextBox.Text, PWPlain, AUTH_TYPEComboBox.Text, txtAttachment.Text, True) = True Then
MsgBox("Email(s) has/have been sent successfully.", MsgBoxStyle.Information) MsgBox("Email(s) has/have been sent successfully.", MsgBoxStyle.Information)
Else Else
MsgBox("Could not send the testmail. Please check the log.", MsgBoxStyle.Exclamation) MsgBox("Could not send the testmail. Please check the log.", MsgBoxStyle.Exclamation)
End If End If
End If End If
End Sub End Sub
Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click