MS Referenz W-Laufwerk

This commit is contained in:
Digital Data - Marlon Schreiber
2018-12-19 17:09:23 +01:00
parent 0ccd050d4c
commit fb148c193c
24 changed files with 1364 additions and 819 deletions

View File

@@ -7,7 +7,6 @@ Imports System.Globalization
Imports Oracle.ManagedDataAccess.Client
Imports Independentsoft
Imports System.IO
Imports DevExpress.Pdf.pdfdo
Imports DevExpress.Pdf
Imports System.Text.RegularExpressions
Imports System.ComponentModel
@@ -26,7 +25,7 @@ Public Class frmValidator
Dim finalProfile As Boolean
Dim Move2Folder As String
'Private _windreamPM As New ClassPMWindream
'Private _windream As New ClassWindream_allgemein
Private _windream As New ClassWindream_allgemein
Private allgFunk As New ClassAllgemeineFunktionen
Dim aktivesDokument As WMObject
'speichert die DocumentDaten
@@ -1193,12 +1192,13 @@ Public Class frmValidator
If newGUID > 0 Then
If LogErrorsOnly = False Then ClassLogger.Add(" >> newGUID: " & newGUID.ToString, False)
Document_Path = TBPM_PROFILE_FILESTableAdapter.CmdGetFilePath_2_GUID(newGUID)
Document_Path = Document_Path.Replace("W:", "\\windream\objects")
CURRENT_DOC_PATH = Document_Path
If LogErrorsOnly = False Then ClassLogger.Add(" >> Document_Path: " & Document_Path, False)
If LogErrorsOnly = False Then ClassLogger.Add(" >> Überprüfen ob File existiert?", False)
Dim i As Integer = 0
Do While allgFunk.file_exists(Document_Path, False) = False And newGUID <> 0
Do While allgFunk.file_exists(Document_Path, _windream) = False And newGUID <> 0
i = i + 1
If i > 800 Then
allgFunk.Insert_LogEntry(CURRENT_ProfilGUID, "Get_Next_GUID - Datei nicht vorhanden!", Environment.UserName)
@@ -1331,13 +1331,13 @@ Public Class frmValidator
TBPM_PROFILE_FILESTableAdapter.CmdSETWORK(True, Environment.UserName, CURRENT_DOC_GUID)
' ############ Infos eintragen #################
tsslblDocID.Text = "Document-ID: " & CURRENT_DOC_ID & " - DocGUID: " & CURRENT_DOC_GUID
txtDateipfad.Text = Document_Path
' txtDateipfad.Text = Document_Path
tstrlbl_Info.Text = "Datei " & docCounter.ToString & " von " & Anzahl_ValDoks.ToString
ClassLogger.Add(">> Validierung für Dokument '" & Document_Path & "' gestartet", False)
Try
'aktivesDokument = _windreamPM.oSession.GetWMObjectByPath(WMEntity.WMEntityDocument, Document_Path.Substring(2))
aktivesDokument = WINDREAM.oSession.GetWMObjectByPath(WMEntity.WMEntityDocument, Document_Path.Substring(2))
aktivesDokument = WINDREAM.oSession.GetWMObjectByPath(WMEntity.WMEntityDocument, Document_Path.Replace("\\windream\objects",""))
Catch ex As Exception
allgFunk.Insert_LogEntry(CURRENT_ProfilGUID, "Fehler bei Erzeugen windream-Objekt - DocGUID: " & CURRENT_DOC_GUID & " - ERROR: " & ex.Message, Environment.UserName)
ClassLogger.Add("Fehler bei Erzeugen windream-Objekt in (LoadNextDokument): " & ex.Message)
@@ -1565,7 +1565,7 @@ Public Class frmValidator
End Sub
Private Function Windream_get_Doc_info()
Try
Dim DMSErstellt As String
'If CultureInfo.CurrentUICulture.ThreeLetterISOLanguageName = "eng" Then
' My.Settings.vIDX_DMS_ERSTELLT = "DMS Created"
' dmsCreated = "DMS Created"
@@ -1576,7 +1576,7 @@ Public Class frmValidator
'End If
Try
DMSErstellt = aktivesDokument.GetVariableValue(IDX_DMS_ERSTELLT)
CURRENT_DOC_CREATION_DATE = aktivesDokument.GetVariableValue(IDX_DMS_ERSTELLT)
Catch ex As Exception
If ex.Message.Contains("Variable: " & IDX_DMS_ERSTELLT & " not found!") Then
ClassLogger.Add("1. Ausnahme in Windream_get_Doc_info: Variable: " & IDX_DMS_ERSTELLT & " not found", True)
@@ -1593,17 +1593,17 @@ Public Class frmValidator
SaveMySettingsValue("IDX_DMS_ERSTELLT_ZEIT", "DMS erstellt Time")
End If
DMSErstellt = aktivesDokument.GetVariableValue(IDX_DMS_ERSTELLT)
CURRENT_DOC_CREATION_DATE = aktivesDokument.GetVariableValue(IDX_DMS_ERSTELLT)
Else
ClassLogger.Add("Fehler in Windream_get_Doc_info 1: " & ex.Message)
Return "Fehler in Windream_get_Doc_info 1: " & ex.Message
End If
End Try
If LogErrorsOnly = False Then ClassLogger.Add(" >> DMS-Erstellt aus WD: " & DMSErstellt, False)
Dim DMSErstelltZeit As String
If LogErrorsOnly = False Then ClassLogger.Add(" >> DMS-Erstellt aus WD: " & CURRENT_DOC_CREATION_DATE, False)
Try
DMSErstelltZeit = aktivesDokument.GetVariableValue(IDX_DMS_ERSTELLT_ZEIT)
CURRENT_DOC_CREATION_TIME = aktivesDokument.GetVariableValue(IDX_DMS_ERSTELLT_ZEIT)
Catch ex As Exception
If ex.Message.Contains("Variable: " & IDX_DMS_ERSTELLT_ZEIT & " not found!") Then
ClassLogger.Add("1. Ausnahme in Windream_get_Doc_info: Variable: " & IDX_DMS_ERSTELLT_ZEIT & " not found", True)
@@ -1617,19 +1617,19 @@ Public Class frmValidator
SaveMySettingsValue("IDX_DMS_ERSTELLT_ZEIT", "DMS Created Time")
End If
DMSErstelltZeit = aktivesDokument.GetVariableValue(IDX_DMS_ERSTELLT_ZEIT)
CURRENT_DOC_CREATION_TIME = aktivesDokument.GetVariableValue(IDX_DMS_ERSTELLT_ZEIT)
Else
ClassLogger.Add("Fehler in Windream_get_Doc_info 3: " & ex.Message)
Return "Fehler in Windream_get_Doc_info 3: " & ex.Message
End If
End Try
If LogErrorsOnly = False Then ClassLogger.Add(" >> DMSErstelltZeit aus WD: " & DMSErstelltZeit, False)
If LogErrorsOnly = False Then ClassLogger.Add(" >> DMSErstelltZeit aus WD: " & CURRENT_DOC_CREATION_TIME, False)
If DMSErstelltZeit.Length > 11 Then
txtErstellt.Text = DMSErstellt & " " & DMSErstelltZeit.Substring(10)
If CURRENT_DOC_CREATION_TIME.Length > 11 Then
CURRENT_DOC_CREATION_DATE = CURRENT_DOC_CREATION_DATE & " " & CURRENT_DOC_CREATION_TIME.Substring(10)
Else
txtErstellt.Text = DMSErstellt & " " & DMSErstelltZeit
CURRENT_DOC_CREATION_DATE = CURRENT_DOC_CREATION_DATE & " " & CURRENT_DOC_CREATION_TIME
End If
Return ""
@@ -2307,7 +2307,7 @@ Public Class frmValidator
'wenn Move2Folder aktiviert wurde
If Move2Folder <> "" Then
idxerr_message = allgFunk.Move2Folder(Document_Path, Move2Folder, CURRENT_ProfilGUID)
idxerr_message = allgFunk.Move2Folder(Document_Path, Move2Folder, CURRENT_ProfilGUID, _windream)
If idxerr_message <> "" Then
errormessage = "Fehler bei Move2Folder:" & vbNewLine & idxerr_message
My.Settings.Save()
@@ -2316,7 +2316,7 @@ Public Class frmValidator
End If
End If
'Validierungsfile löschen wenn vorhanden
allgFunk.Delete_xffres(Document_Path)
allgFunk.Delete_xffres(Document_Path, _windream)
If LogErrorsOnly = False Then ClassLogger.Add(" >> Delete_xffres ausgeführt", False)
If LogErrorsOnly = False Then ClassLogger.Add(" >> All Input clear", False)
Anzahl_validierte_Dok += 1
@@ -2940,7 +2940,7 @@ Public Class frmValidator
Close_document_viewer()
'Aus der Tabelle löschen
TBPM_PROFILE_FILESTableAdapter.CmdDelete(CURRENT_DOC_GUID)
Dim resul = allgFunk.Delete_xffres(Document_Path)
Dim resul = allgFunk.Delete_xffres(Document_Path, _windream)
If resul = Nothing Or resul = True Then
If Delete_File() = True Then
'MsgBox("Die Datei wurde erfolgreich aus windream gelöscht!" & vbNewLine & "Es wird nun die nächste Datei angezeigt!", MsgBoxStyle.Information, "Erfolgsmeldung:")
@@ -3112,4 +3112,8 @@ Public Class frmValidator
Private Sub frmValidator_Resize(sender As Object, e As EventArgs) Handles Me.Resize
End Sub
Private Sub DateiInfoToolStripMenuItem_Click(sender As Object, e As EventArgs) Handles DateiInfoToolStripMenuItem.Click
frmFileInfo.ShowDialog()
End Sub
End Class