Anlage des Repos
This commit is contained in:
@@ -0,0 +1,115 @@
|
||||
' DeleteExportWinLineDoc_Record
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine löscht einen Datensatz anhand einer selktierten Gridzeile.
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
' Parameter 2 (GRID) = Falls mehrere Grids auf einem Level vorkommen, kann über diesen Parameter nochmals unterscheiden werden.
|
||||
' Parameter 3 (ROW) = Zu löschende Zeile im Grid (nur zwecks Anzeige).
|
||||
' Parameter 4 (GRID) = Eindeutige Nummer des zu löschenden Datensatzes (zwecks Löschung in der DB).
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 04.07.2021 / MD
|
||||
' Version Date / Editor: 04.07.2021 / MD
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub DeleteExportWinLineDoc_Record(LEVEL,GRID,ROW,GUID)
|
||||
|
||||
If (((LEVEL = 1) or (LEVEL = "1")) and (ROW > 0) and (GUID > 0)) Then
|
||||
|
||||
If (GRID = LEVEL1_GRID_ID) Then
|
||||
|
||||
MsgBoxQuestion = MsgBox ("Möchten Sie den ausgewählten Datensatz wirklich löschen? " & vbCrlf & vbCrlf & _
|
||||
"Beschreibung: " & LEVEL1_GRID_CURRENT_Beschreibung & vbCrlf & vbCrlf & _
|
||||
"Mandant: " & LEVEL1_GRID_CURRENT_Mandant & vbCrlf & vbCrlf & _
|
||||
"Achtung der Vorgang kann nicht Rückgängig gemacht werden!" & vbCrlf & _
|
||||
"", vbYesno+vbQuestion, DEFAULT_TITLE & " - Löschen bestätigen!")
|
||||
|
||||
If (MsgBoxQuestion = 6) Then
|
||||
|
||||
SQLDelete_Profile = REPLACE(SQLDelete_Profile_Template,"%GUID%",GUID)
|
||||
SQLResult_Profile = Conn.ExecuteSQL(SQLDelete_Profile)
|
||||
|
||||
If (SQLResult_Profile = "Wahr") Or (SQLResult_Profile = 1) Then
|
||||
|
||||
LEVEL1_Grid.RemoveLine ROW
|
||||
'LEVEL1_Grid.Refresh << Dont do this selected line will lose
|
||||
|
||||
If (LEVEL1_Grid.LineCount > 0) Then
|
||||
|
||||
'Show updated count down the table
|
||||
LEVEL1_TXT_TabelCounter.Contents = (Cstr(LEVEL1_Grid.LineCount) & " Zuordnungen gefunden")
|
||||
|
||||
Else
|
||||
|
||||
LEVEL1_TXT_TabelCounter.Contents = "Keine Zuordnungen gefunden"
|
||||
|
||||
End If
|
||||
|
||||
MsgBox "Der Datensatz wurde erfolgreich gelöscht!",vbOkayonly+vbInformation,DEFAULT_TITLE & " - Erfolg!"
|
||||
|
||||
Else
|
||||
MsgBox "Der Datensatz konnte nicht gelöscht werden!",vbOkayonly+vbCritical,DEFAULT_TITLE & " - Fehler!"
|
||||
|
||||
End If
|
||||
|
||||
End if
|
||||
|
||||
End If
|
||||
|
||||
ElseIf (((LEVEL = 2) or (LEVEL = "2")) and (ROW > 0) and (GUID > 0)) Then
|
||||
|
||||
If (GRID = LEVEL2_GRID_ID) Then
|
||||
|
||||
MsgBoxQuestion = MsgBox ("Möchten Sie den ausgewählten Datensatz wirklich löschen? " & vbCrlf & vbCrlf & _
|
||||
"Beschreibung: " & LEVEL2_GRID_CURRENT_Beschreibung & vbCrlf & vbCrlf & _
|
||||
"Mandant: " & LEVEL2_GRID_CURRENT_Mandant & vbCrlf & vbCrlf & _
|
||||
"Achtung der Vorgang kann nicht Rückgängig gemacht werden!" & vbCrlf & _
|
||||
"", vbYesno+vbQuestion, DEFAULT_TITLE & " - Löschen bestätigen!")
|
||||
|
||||
If (MsgBoxQuestion = 6) Then
|
||||
|
||||
SQLDelete_Config = REPLACE(SQLDelete_Config_Template,"%GUID%",GUID)
|
||||
SQLResult_Config = Conn.ExecuteSQL(SQLDelete_Config)
|
||||
|
||||
If (SQLResult_Config = "Wahr") Or (SQLResult_Config = 1) Then
|
||||
|
||||
LEVEL2_Grid.RemoveLine ROW
|
||||
'LEVEL2_Grid.Refresh << Dont do this selected line will lose
|
||||
|
||||
If (LEVEL2_Grid.LineCount > 0) Then
|
||||
|
||||
'Show updated count down the table
|
||||
LEVEL2_TXT_TabelCounter.Contents = (Cstr(LEVEL2_Grid.LineCount) & " Zuordnungen gefunden")
|
||||
|
||||
Else
|
||||
|
||||
LEVEL2_TXT_TabelCounter.Contents = "Keine Zuordnungen gefunden"
|
||||
|
||||
End If
|
||||
|
||||
MsgBox "Der Datensatz wurde erfolgreich gelöscht!",vbOkayonly+vbInformation,DEFAULT_TITLE & " - Erfolg!"
|
||||
|
||||
Else
|
||||
MsgBox "Der Datensatz konnte nicht gelöscht werden!",vbOkayonly+vbCritical,DEFAULT_TITLE & " - Fehler!"
|
||||
|
||||
End If
|
||||
|
||||
End if
|
||||
|
||||
Else
|
||||
|
||||
Msgbox "Unzureichende Parameter!" & vbCrlf & _
|
||||
"LEVEL: " & LEVEL & vbCrlf & _
|
||||
"ROW: " & ROW & vbCrlf & _
|
||||
"GUID: " & GUID & vbCrlf & _
|
||||
"",vbOkayonly+vbCritical,DEFAULT_TITLE & " - Fehler!"
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
End Sub
|
||||
@@ -0,0 +1,91 @@
|
||||
' DD-INSERT_LANGBESCHINT_INTO_BELEGERFASSUNG
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine deaktiviert Knöpfe im Ribbon und in Fenster.
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
' Parameter 2 (CTRLType)= "Static" deaktiviert pauschal, "dynamic" deaktiviert anhand anderer Laufzeitvariablen.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 16.07.2021 / MK
|
||||
' Version Date / Editor: 16.07.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub DisableExportWinLineDoc_ButtonControls(LEVEL,CTRLType)
|
||||
|
||||
If ((LEVEL = 0) or (LEVEL = "0")) and (CTRLType = "static") Then
|
||||
|
||||
LEVEL0_BTN_ABORT.Active = False
|
||||
|
||||
ElseIf ((LEVEL = 1) or (LEVEL = "1")) and (CTRLType = "static") Then
|
||||
|
||||
LEVEL0_BTN_OK.Active = False
|
||||
LEVEL0_BTN_EXIT.Active = False
|
||||
|
||||
LEVEL1_TAB_LEVEL1_TO_LEVEL1.Active = False
|
||||
LEVEL1_TAB_LEVEL1_TO_LEVEL2.Active = False
|
||||
LEVEL1_TAB_LEVEL1_TO_LEVEL3.Active = False
|
||||
|
||||
ElseIf ((LEVEL = 2) or (LEVEL = "2")) and (CTRLType = "static") Then
|
||||
|
||||
LEVEL0_BTN_OK.Active = False
|
||||
LEVEL0_BTN_EXIT.Active = False
|
||||
|
||||
LEVEL2_TAB_LEVEL2_TO_LEVEL1.Active = False
|
||||
LEVEL2_TAB_LEVEL2_TO_LEVEL2.Active = False
|
||||
LEVEL2_TAB_LEVEL2_TO_LEVEL3.Active = False
|
||||
|
||||
ElseIf ((LEVEL = 1) or (LEVEL = "1")) and (CTRLType = "dynamic") Then
|
||||
|
||||
If (LEVEL1_GRID_CURRENT_GUID = -1) Then
|
||||
|
||||
LEVEL0_BTN_NEW.Active = False
|
||||
LEVEL0_BTN_DELETE.Active = False
|
||||
|
||||
ElseIf (LEVEL1_GRID_CURRENT_ROW >= 0) and (LEVEL1_GRID_CURRENT_GUID >= 0) Then
|
||||
|
||||
LEVEL0_BTN_ABORT.Active = False
|
||||
LEVEL0_BTN_SAVE.Active = False
|
||||
LEVEL0_BTN_DELETE.Active = False
|
||||
|
||||
ElseIf (LEVEL1_GRID_CURRENT_ROW <= 0) and (LEVEL1_GRID_CURRENT_GUID <= 0) Then
|
||||
|
||||
LEVEL0_BTN_SAVE.Active = False
|
||||
LEVEL0_BTN_DELETE.Active = False
|
||||
|
||||
End if
|
||||
|
||||
ElseIf ((LEVEL = 2) or (LEVEL = "2")) and (CTRLType = "dynamic") Then
|
||||
|
||||
If (LEVEL2_GRID_CURRENT_GUID = -1) Then
|
||||
|
||||
LEVEL0_BTN_NEW.Active = False
|
||||
LEVEL0_BTN_DELETE.Active = False
|
||||
|
||||
ElseIf (LEVEL2_GRID_CURRENT_ROW >= 0) and (LEVEL2_GRID_CURRENT_GUID >= 0) Then
|
||||
|
||||
LEVEL0_BTN_ABORT.Active = False
|
||||
LEVEL0_BTN_SAVE.Active = False
|
||||
LEVEL0_BTN_DELETE.Active = False
|
||||
|
||||
ElseIf (LEVEL2_GRID_CURRENT_ROW <= 0) and (LEVEL2_GRID_CURRENT_GUID <= 0) Then
|
||||
|
||||
LEVEL0_BTN_SAVE.Active = False
|
||||
LEVEL0_BTN_DELETE.Active = False
|
||||
|
||||
End if
|
||||
|
||||
ElseIf ((LEVEL = 3) or (LEVEL = "3")) and (CTRLType = "static") Then
|
||||
|
||||
LEVEL0_BTN_OK.Active = False
|
||||
LEVEL0_BTN_NEW.Active = False
|
||||
LEVEL0_BTN_DELETE.Active = False
|
||||
LEVEL0_BTN_SAVE.Active = False
|
||||
LEVEL0_BTN_DELETE.Active = False
|
||||
|
||||
End if
|
||||
|
||||
End Sub
|
||||
@@ -0,0 +1,141 @@
|
||||
' DisableExportWinLineDoc_InputControls
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine deaktiviert sämtliche Eingabefelder auf einem Level.
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
' Parameter 2 (CTRLType)= "Static" deaktiviert pauschal, "dynamic" deaktiviert anhand anderer Laufzeitvariablen.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 15.07.2021 / MK
|
||||
' Version Date / Editor: 15.07.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub DisableExportWinLineDoc_InputControls(LEVEL,CTRLType)
|
||||
|
||||
If ((LEVEL = 1) or (LEVEL = "1")) and (CTRLType = "static") Then
|
||||
|
||||
LEVEL1_CHK_Aktiv.Active = False
|
||||
LEVEL1_TXT_Beschreibung.Active = False
|
||||
LEVEL1_TXT_Mandant.Active = False
|
||||
|
||||
LEVEL1_TXT_WinLineVariable1.Active = False
|
||||
LEVEL1_TXT_WinLineVariable2.Active = False
|
||||
LEVEL1_TXT_WinLineVariable3.Active = False
|
||||
LEVEL1_TXT_WinLineVariable4.Active = False
|
||||
LEVEL1_TXT_WinLineVariable5.Active = False
|
||||
LEVEL1_TXT_WinLineVariable6.Active = False
|
||||
LEVEL1_TXT_WinLineVariable7.Active = False
|
||||
LEVEL1_TXT_WinLineVariable8.Active = False
|
||||
LEVEL1_TXT_WinLineVariable9.Active = False
|
||||
LEVEL1_TXT_WinLineVariable10.Active = False
|
||||
|
||||
LEVEL1_TXT_CallMakroPreExport1.Active = False
|
||||
LEVEL1_TXT_CallMakroPreExport2.Active = False
|
||||
LEVEL1_TXT_CallMakroPreExport3.Active = False
|
||||
LEVEL1_TXT_CallMakroPreExport4.Active = False
|
||||
LEVEL1_TXT_CallMakroPreExport5.Active = False
|
||||
LEVEL1_TXT_CallMakroPreExport6.Active = False
|
||||
LEVEL1_TXT_CallMakroPreExport7.Active = False
|
||||
LEVEL1_TXT_CallMakroPreExport8.Active = False
|
||||
LEVEL1_TXT_CallMakroPreExport9.Active = False
|
||||
LEVEL1_TXT_CallMakroPreExport10.Active = False
|
||||
|
||||
LEVEL1_TXT_ExportPfad.Active = False
|
||||
LEVEL1_TXT_ExportDateiname.Active = False
|
||||
LEVEL1_TXT_ExportDateinameVorschau.Active = False
|
||||
LEVEL1_TXT_ExportDateiendung.Active = False
|
||||
LEVEL1_TXT_ExportVersionierung.Active = False
|
||||
LEVEL1_BTN_VariableEinfuegen1.Active = False
|
||||
LEVEL1_BTN_VariableEinfuegen2.Active = False
|
||||
LEVEL1_BTN_VariableEinfuegen3.Active = False
|
||||
|
||||
ElseIf ((LEVEL = 2) or (LEVEL = "2")) and (CTRLType = "static") Then
|
||||
|
||||
LEVEL2_CHK_Aktiv.Active = False
|
||||
LEVEL2_TXT_Beschreibung.Active = False
|
||||
LEVEL2_TXT_Mandant.Active = False
|
||||
|
||||
LEVEL2_TXT_Eintragstyp.Active = False
|
||||
LEVEL2_TXT_Platzhalter.Active = False
|
||||
LEVEL2_TXT_Datentyp.Active = False
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Active = False
|
||||
LEVEL2_TXT_Integer_Wert.Active = False
|
||||
LEVEL2_TXT_Double_Wert.Active = False
|
||||
LEVEL2_TXT_Date_Wert.Active = False
|
||||
|
||||
ElseIf ((LEVEL = 2) or (LEVEL = "2")) and (CTRLType = "dynamic") Then
|
||||
|
||||
IF (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Text", vbTextCompare ) > 0) Then
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Active = True
|
||||
|
||||
LEVEL2_TXT_Integer_Wert.Active = True
|
||||
LEVEL2_TXT_Integer_Wert.Contents = 0
|
||||
LEVEL2_TXT_Integer_Wert.Active = False
|
||||
|
||||
LEVEL2_TXT_Double_Wert.Active = True
|
||||
LEVEL2_TXT_Double_Wert.Contents = 0.0
|
||||
LEVEL2_TXT_Double_Wert.Active = False
|
||||
|
||||
LEVEL2_TXT_Date_Wert.Active = True
|
||||
LEVEL2_TXT_Date_Wert.Contents = "01.01.1970"
|
||||
LEVEL2_TXT_Date_Wert.Active = False
|
||||
|
||||
ElseIf (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Integer", vbTextCompare ) > 0) Then
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Active = True
|
||||
LEVEL2_TXT_Text_Wert.Contents = ""
|
||||
LEVEL2_TXT_Text_Wert.Active = False
|
||||
|
||||
LEVEL2_TXT_Integer_Wert.Active = True
|
||||
|
||||
LEVEL2_TXT_Double_Wert.Active = True
|
||||
LEVEL2_TXT_Double_Wert.Contents = 0.0
|
||||
LEVEL2_TXT_Double_Wert.Active = False
|
||||
|
||||
LEVEL2_TXT_Date_Wert.Active = True
|
||||
LEVEL2_TXT_Date_Wert.Contents = "01.01.1970"
|
||||
LEVEL2_TXT_Date_Wert.Active = False
|
||||
|
||||
ElseIf (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Double", vbTextCompare ) > 0) Then
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Active = True
|
||||
LEVEL2_TXT_Text_Wert.Contents = ""
|
||||
LEVEL2_TXT_Text_Wert.Active = False
|
||||
|
||||
LEVEL2_TXT_Integer_Wert.Active = True
|
||||
LEVEL2_TXT_Integer_Wert.Contents = 0
|
||||
LEVEL2_TXT_Integer_Wert.Active = False
|
||||
|
||||
LEVEL2_TXT_Double_Wert.Active = True
|
||||
|
||||
LEVEL2_TXT_Date_Wert.Active = True
|
||||
LEVEL2_TXT_Date_Wert.Contents = "01.01.1970"
|
||||
LEVEL2_TXT_Date_Wert.Active = False
|
||||
|
||||
ElseIf (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Date", vbTextCompare ) > 0) Then
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Active = True
|
||||
LEVEL2_TXT_Text_Wert.Contents = ""
|
||||
LEVEL2_TXT_Text_Wert.Active = False
|
||||
|
||||
LEVEL2_TXT_Integer_Wert.Active = True
|
||||
LEVEL2_TXT_Integer_Wert.Contents = 0
|
||||
LEVEL2_TXT_Integer_Wert.Active = False
|
||||
|
||||
LEVEL2_TXT_Double_Wert.Active = True
|
||||
LEVEL2_TXT_Double_Wert.Contents = 0.0
|
||||
LEVEL2_TXT_Double_Wert.Active = False
|
||||
|
||||
LEVEL2_TXT_Date_Wert.Active = True
|
||||
|
||||
End if
|
||||
|
||||
End if
|
||||
|
||||
End Sub
|
||||
@@ -0,0 +1,85 @@
|
||||
' EnableExportWinLineDoc_ButtonControls
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine aktiviert Knöpfe im Ribbon und in Fenster.
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
' Parameter 2 (CTRLType)= "Static" aktiviert pauschal, "dynamic" aktiviert anhand anderer Laufzeitvariablen.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 29.06.2021 / MK
|
||||
' Version Date / Editor: 29.06.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub EnableExportWinLineDoc_ButtonControls(LEVEL,CTRLType)
|
||||
|
||||
If ((LEVEL = 0) or (LEVEL = "0")) and (CTRLType = "static") Then
|
||||
|
||||
LEVEL0_BTN_ABORT.Active = True
|
||||
|
||||
ElseIf ((LEVEL = 1) or (LEVEL = "1")) and (CTRLType = "static") Then
|
||||
|
||||
LEVEL0_BTN_OK.Active = True
|
||||
LEVEL0_BTN_EXIT.Active = True
|
||||
|
||||
LEVEL1_TAB_LEVEL1_TO_LEVEL1.Active = True
|
||||
LEVEL1_TAB_LEVEL1_TO_LEVEL2.Active = True
|
||||
LEVEL1_TAB_LEVEL1_TO_LEVEL3.Active = True
|
||||
|
||||
ElseIf ((LEVEL = 2) or (LEVEL = "2")) and (CTRLType = "static") Then
|
||||
|
||||
LEVEL0_BTN_OK.Active = True
|
||||
LEVEL0_BTN_EXIT.Active = True
|
||||
|
||||
LEVEL2_TAB_LEVEL2_TO_LEVEL1.Active = True
|
||||
LEVEL2_TAB_LEVEL2_TO_LEVEL2.Active = True
|
||||
LEVEL2_TAB_LEVEL2_TO_LEVEL3.Active = True
|
||||
|
||||
ElseIf ((LEVEL = 1) or (LEVEL = "1")) and (CTRLType = "dynamic") Then
|
||||
|
||||
If (LEVEL1_GRID_CURRENT_GUID = -1) Then
|
||||
|
||||
LEVEL0_BTN_ABORT.Active = TRUE
|
||||
LEVEL0_BTN_SAVE.Active = True
|
||||
|
||||
ElseIf (LEVEL1_GRID_CURRENT_ROW > 0) and (LEVEL1_GRID_CURRENT_GUID > 0) Then
|
||||
|
||||
LEVEL0_BTN_OK.Active = True
|
||||
LEVEL0_BTN_NEW.Active = True
|
||||
LEVEL0_BTN_SAVE.Active = True
|
||||
LEVEL0_BTN_DELETE.Active = True
|
||||
|
||||
ElseIf (LEVEL1_GRID_CURRENT_ROW = 0) and (LEVEL1_GRID_CURRENT_GUID = 0) Then
|
||||
|
||||
LEVEL0_BTN_OK.Active = True
|
||||
LEVEL0_BTN_NEW.Active = True
|
||||
|
||||
End if
|
||||
|
||||
ElseIf ((LEVEL = 2) or (LEVEL = "2")) and (CTRLType = "dynamic") Then
|
||||
|
||||
If (LEVEL2_GRID_CURRENT_GUID = -1) Then
|
||||
|
||||
LEVEL0_BTN_ABORT.Active = TRUE
|
||||
LEVEL0_BTN_SAVE.Active = True
|
||||
|
||||
ElseIf (LEVEL2_GRID_CURRENT_ROW > 0) and (LEVEL2_GRID_CURRENT_GUID > 0) Then
|
||||
|
||||
LEVEL0_BTN_OK.Active = True
|
||||
LEVEL0_BTN_NEW.Active = True
|
||||
LEVEL0_BTN_SAVE.Active = True
|
||||
LEVEL0_BTN_DELETE.Active = True
|
||||
|
||||
ElseIf (LEVEL2_GRID_CURRENT_ROW = 0) and (LEVEL2_GRID_CURRENT_GUID = 0) Then
|
||||
|
||||
LEVEL0_BTN_OK.Active = True
|
||||
LEVEL0_BTN_NEW.Active = True
|
||||
|
||||
End if
|
||||
|
||||
End if
|
||||
|
||||
End Sub
|
||||
@@ -0,0 +1,105 @@
|
||||
' EnableExportWinLineDoc_InputControls
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine aktiviert sämtliche Eingabefelder auf einem Level.
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
' Parameter 2 (CTRLType)= "Static" aktiviert pauschal, "dynamic" aktiviert anhand anderer Laufzeitvariablen.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 17.06.2021 / MD
|
||||
' Version Date / Editor: 17.06.2021 / MD
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub EnableExportWinLineDoc_InputControls(LEVEL,CTRLType)
|
||||
|
||||
If ((LEVEL = 1) or (LEVEL = "1")) and ((CTRLType = "dynamic") or (CTRLType = "static")) Then
|
||||
|
||||
LEVEL1_CHK_Aktiv.Active = true
|
||||
LEVEL1_TXT_Beschreibung.Active = true
|
||||
LEVEL1_TXT_Mandant.Active = true
|
||||
|
||||
LEVEL1_TXT_WinLineVariable1.Active = true
|
||||
LEVEL1_TXT_WinLineVariable2.Active = true
|
||||
LEVEL1_TXT_WinLineVariable3.Active = true
|
||||
LEVEL1_TXT_WinLineVariable4.Active = true
|
||||
LEVEL1_TXT_WinLineVariable5.Active = true
|
||||
LEVEL1_TXT_WinLineVariable6.Active = true
|
||||
LEVEL1_TXT_WinLineVariable7.Active = true
|
||||
LEVEL1_TXT_WinLineVariable8.Active = true
|
||||
LEVEL1_TXT_WinLineVariable9.Active = true
|
||||
LEVEL1_TXT_WinLineVariable10.Active = true
|
||||
|
||||
LEVEL1_TXT_CallMakroPreExport1.Active = true
|
||||
LEVEL1_TXT_CallMakroPreExport2.Active = true
|
||||
LEVEL1_TXT_CallMakroPreExport3.Active = true
|
||||
LEVEL1_TXT_CallMakroPreExport4.Active = true
|
||||
LEVEL1_TXT_CallMakroPreExport5.Active = true
|
||||
LEVEL1_TXT_CallMakroPreExport6.Active = true
|
||||
LEVEL1_TXT_CallMakroPreExport7.Active = true
|
||||
LEVEL1_TXT_CallMakroPreExport8.Active = true
|
||||
LEVEL1_TXT_CallMakroPreExport9.Active = true
|
||||
LEVEL1_TXT_CallMakroPreExport10.Active = true
|
||||
|
||||
LEVEL1_TXT_ExportPfad.Active = true
|
||||
LEVEL1_TXT_ExportDateiname.Active = true
|
||||
LEVEL1_TXT_ExportDateinameVorschau.Active = true
|
||||
LEVEL1_TXT_ExportDateiendung.Active = true
|
||||
LEVEL1_TXT_ExportVersionierung.Active = true
|
||||
LEVEL1_BTN_VariableEinfuegen1.Active = true
|
||||
LEVEL1_BTN_VariableEinfuegen2.Active = true
|
||||
LEVEL1_BTN_VariableEinfuegen3.Active = true
|
||||
|
||||
ElseIf ((LEVEL = 2) or (LEVEL = "2")) and (CTRLType = "static") Then
|
||||
|
||||
LEVEL2_CHK_Aktiv.Active = True
|
||||
LEVEL2_TXT_Beschreibung.Active = True
|
||||
LEVEL2_TXT_Mandant.Active = True
|
||||
|
||||
LEVEL2_TXT_Eintragstyp.Active = True
|
||||
LEVEL2_TXT_Platzhalter.Active = True
|
||||
LEVEL2_TXT_Datentyp.Active = True
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Active = True
|
||||
LEVEL2_TXT_Integer_Wert.Active = True
|
||||
LEVEL2_TXT_Double_Wert.Active = True
|
||||
LEVEL2_TXT_Date_Wert.Active = True
|
||||
|
||||
ElseIf ((LEVEL = 2) or (LEVEL = "2")) and (CTRLType = "dynamic") Then
|
||||
|
||||
IF (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Text", vbTextCompare ) > 0) Then
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Active = True
|
||||
LEVEL2_TXT_Integer_Wert.Active = False
|
||||
LEVEL2_TXT_Double_Wert.Active = False
|
||||
LEVEL2_TXT_Date_Wert.Active = False
|
||||
|
||||
ElseIf (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Integer", vbTextCompare ) > 0) Then
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Active = False
|
||||
LEVEL2_TXT_Integer_Wert.Active = True
|
||||
LEVEL2_TXT_Double_Wert.Active = False
|
||||
LEVEL2_TXT_Date_Wert.Active = False
|
||||
|
||||
ElseIf (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Double", vbTextCompare ) > 0) Then
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Active = False
|
||||
LEVEL2_TXT_Integer_Wert.Active = False
|
||||
LEVEL2_TXT_Double_Wert.Active = True
|
||||
LEVEL2_TXT_Date_Wert.Active = False
|
||||
|
||||
ElseIf (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Date", vbTextCompare ) > 0) Then
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Active = False
|
||||
LEVEL2_TXT_Integer_Wert.Active = False
|
||||
LEVEL2_TXT_Double_Wert.Active = False
|
||||
LEVEL2_TXT_Date_Wert.Active = True
|
||||
|
||||
End if
|
||||
|
||||
End if
|
||||
|
||||
End Sub
|
||||
52
archive/Export-WinLineDoc/Modules/Encode VBS to VBME.vbs
Normal file
52
archive/Export-WinLineDoc/Modules/Encode VBS to VBME.vbs
Normal file
@@ -0,0 +1,52 @@
|
||||
'*****************************************************
|
||||
'************ Autor: Boris Toll ************
|
||||
'P: SCRENC //////
|
||||
'12:2004 //////
|
||||
'File: toVBE.vbs //////
|
||||
'*****************************************************
|
||||
' # Description:: Drag & drop the File to encode over the Script
|
||||
|
||||
If WScript.Arguments.Count = 0 Then
|
||||
WScript.Echo "Kein Parameter angegeben"
|
||||
Else
|
||||
On Error Resume Next
|
||||
|
||||
Set fso = CreateObject("Scripting.FileSystemObject")
|
||||
|
||||
For each Argument in WScript.Arguments
|
||||
skript = skript & Argument & " "
|
||||
Next
|
||||
|
||||
Set Codex = fso.OpenTextFile(skript)
|
||||
code = Codex.ReadAll
|
||||
CHKerr()
|
||||
Codex.close
|
||||
|
||||
Set SEncod = CreateObject("Scripting.Encoder")
|
||||
newcode = SEncod.EncodeScriptFile(".vbs", code, 0, "")
|
||||
|
||||
script = fso.GetBaseName(skript)
|
||||
path = fso.GetParentFolderName(skript)
|
||||
|
||||
newname = script & ".vbme"
|
||||
newpathname = fso.BuildPath(path, newname)
|
||||
|
||||
Set newfile = fso.CreateTextFile(newpathname, true)
|
||||
newfile.Write newcode
|
||||
newfile.close
|
||||
|
||||
end if
|
||||
|
||||
Private Function CHKerr()
|
||||
|
||||
if err.number <> 0 then
|
||||
if err.number = 62 then
|
||||
WScript.echo "Fehlercode: " & err.number & vbcrlf & err.description & vbcrlf & "Leere Dateien können nicht umgewandelt werden"
|
||||
err.clear
|
||||
else
|
||||
WScript.echo "Fehlercode: " & err.number & vbcrlf & err.description
|
||||
err.clear
|
||||
end if
|
||||
end if
|
||||
|
||||
End Function
|
||||
107
archive/Export-WinLineDoc/Modules/GetExportWinLineDoc_Record.vbm
Normal file
107
archive/Export-WinLineDoc/Modules/GetExportWinLineDoc_Record.vbm
Normal file
@@ -0,0 +1,107 @@
|
||||
' GetExportWinLineDoc_Record
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine läd Daten in Zwischenvariabelen.
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
' Parameter 2 (GRID) = Falls mehrere Grids auf einem Level vorkommen, kann über diesen Parameter nochmals unterscheiden werden.
|
||||
' Parameter 2 (CURRENT_GUID)= Anhand dieser eindeutgen Nummer wird der Datensatz in der DB identifiziert.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 14.06.2021 / MK
|
||||
' Version Date / Editor: 14.06.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub GetExportWinLineDoc_Record(LEVEL,GRID,CURRENT_GUID)
|
||||
|
||||
If (LEVEL = 1) or (LEVEL = "1") Then
|
||||
|
||||
If (GRID = LEVEL1_GRID_ID) Then
|
||||
|
||||
SQLQuery_Profile = SQLQuery_Profile_Template
|
||||
SQLQuery_Profile = Replace(SQLQuery_Profile,"%GUID%",LEVEL1_GRID_CURRENT_GUID)
|
||||
|
||||
Set SQLResult_Profile = Conn.Select(SQLQuery_Profile)
|
||||
If (SQLResult_Profile.RowCount = 1) Then
|
||||
|
||||
LEVEL1_TXT_GUID_DBValue = SQLResult_Profile.Value("u000")
|
||||
LEVEL1_CHK_Aktiv_DBValue = SQLResult_Profile.Value("u001")
|
||||
LEVEL1_TXT_Beschreibung_DBValue = SQLResult_Profile.Value("u002")
|
||||
LEVEL1_TXT_Mandant_DBValue = SQLResult_Profile.Value("u003")
|
||||
|
||||
LEVEL1_TXT_WinLineVariable1_DBValue = SQLResult_Profile.Value("u004")
|
||||
LEVEL1_TXT_WinLineVariable2_DBValue = SQLResult_Profile.Value("u005")
|
||||
LEVEL1_TXT_WinLineVariable3_DBValue = SQLResult_Profile.Value("u006")
|
||||
LEVEL1_TXT_WinLineVariable4_DBValue = SQLResult_Profile.Value("u007")
|
||||
LEVEL1_TXT_WinLineVariable5_DBValue = SQLResult_Profile.Value("u008")
|
||||
LEVEL1_TXT_WinLineVariable6_DBValue = SQLResult_Profile.Value("u009")
|
||||
LEVEL1_TXT_WinLineVariable7_DBValue = SQLResult_Profile.Value("u010")
|
||||
LEVEL1_TXT_WinLineVariable8_DBValue = SQLResult_Profile.Value("u011")
|
||||
LEVEL1_TXT_WinLineVariable9_DBValue = SQLResult_Profile.Value("u012")
|
||||
LEVEL1_TXT_WinLineVariable10_DBValue = SQLResult_Profile.Value("u013")
|
||||
|
||||
LEVEL1_TXT_CallMakroPreExport1_DBValue = SQLResult_Profile.Value("u014")
|
||||
LEVEL1_TXT_CallMakroPreExport2_DBValue = SQLResult_Profile.Value("u015")
|
||||
LEVEL1_TXT_CallMakroPreExport3_DBValue = SQLResult_Profile.Value("u016")
|
||||
LEVEL1_TXT_CallMakroPreExport4_DBValue = SQLResult_Profile.Value("u017")
|
||||
LEVEL1_TXT_CallMakroPreExport5_DBValue = SQLResult_Profile.Value("u018")
|
||||
LEVEL1_TXT_CallMakroPreExport6_DBValue = SQLResult_Profile.Value("u019")
|
||||
LEVEL1_TXT_CallMakroPreExport7_DBValue = SQLResult_Profile.Value("u020")
|
||||
LEVEL1_TXT_CallMakroPreExport8_DBValue = SQLResult_Profile.Value("u021")
|
||||
LEVEL1_TXT_CallMakroPreExport9_DBValue = SQLResult_Profile.Value("u022")
|
||||
LEVEL1_TXT_CallMakroPreExport10_DBValue = SQLResult_Profile.Value("u023")
|
||||
|
||||
LEVEL1_TXT_ExportPfad_DBValue = SQLResult_Profile.Value("u024")
|
||||
LEVEL1_TXT_ExportDateiname_DBValue = SQLResult_Profile.Value("u025")
|
||||
LEVEL1_TXT_ExportDateinameVorschau_DBValue = SQLResult_Profile.Value("u026")
|
||||
LEVEL1_TXT_ExportDateiendung_DBValue = SQLResult_Profile.Value("u027")
|
||||
LEVEL1_TXT_ExportVersionierung_DBValue = SQLResult_Profile.Value("u028")
|
||||
|
||||
LEVEL0_TXT_Erstellt_wer_DBValue = SQLResult_Profile.Value("u029")
|
||||
LEVEL0_TXT_Erstellt_wann_DBValue = SQLResult_Profile.Value("u030")
|
||||
LEVEL0_TXT_Geaendert_wer_DBValue = SQLResult_Profile.Value("u031")
|
||||
LEVEL0_TXT_Geaendert_wann_DBValue = SQLResult_Profile.Value("u032")
|
||||
|
||||
End if
|
||||
|
||||
End If
|
||||
|
||||
ElseIf (LEVEL = 2) or (LEVEL = "2") Then
|
||||
|
||||
If (GRID = LEVEL2_GRID_ID) Then
|
||||
|
||||
SQLQuery_Config = SQLQuery_Config_Template
|
||||
SQLQuery_Config = Replace(SQLQuery_Config,"%GUID%",LEVEL2_GRID_CURRENT_GUID)
|
||||
|
||||
Set SQLResult_Config = Conn.Select(SQLQuery_Config)
|
||||
If (SQLResult_Config.RowCount = 1) Then
|
||||
|
||||
LEVEL2_TXT_GUID_DBValue = SQLResult_Config.Value("u000")
|
||||
LEVEL2_CHK_Aktiv_DBValue = SQLResult_Config.Value("u001")
|
||||
LEVEL2_TXT_Beschreibung_DBValue = SQLResult_Config.Value("u002")
|
||||
LEVEL2_TXT_Mandant_DBValue = SQLResult_Config.Value("u003")
|
||||
|
||||
LEVEL2_TXT_Eintragstyp_DBValue = SQLResult_Config.Value("u004")
|
||||
LEVEL2_TXT_Platzhalter_DBValue = SQLResult_Config.Value("u005")
|
||||
LEVEL2_TXT_Datentyp_DBValue = SQLResult_Config.Value("u006")
|
||||
|
||||
LEVEL2_TXT_Text_Wert_DBValue = SQLResult_Config.Value("u007")
|
||||
LEVEL2_TXT_Integer_Wert_DBValue = SQLResult_Config.Value("u008")
|
||||
LEVEL2_TXT_Double_Wert_DBValue = SQLResult_Config.Value("u009")
|
||||
LEVEL2_TXT_Date_Wert_DBValue = SQLResult_Config.Value("u010")
|
||||
|
||||
LEVEL0_TXT_Erstellt_wer_DBValue = SQLResult_Config.Value("u011")
|
||||
LEVEL0_TXT_Erstellt_wann_DBValue = SQLResult_Config.Value("u012")
|
||||
LEVEL0_TXT_Geaendert_wer_DBValue = SQLResult_Config.Value("u013")
|
||||
LEVEL0_TXT_Geaendert_wann_DBValue = SQLResult_Config.Value("u014")
|
||||
|
||||
End if
|
||||
|
||||
End if
|
||||
|
||||
End if
|
||||
|
||||
End Sub
|
||||
@@ -0,0 +1,98 @@
|
||||
' InitializeExportWinLineDoc_CreateVar
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine initialisiert die nötigen Variablen.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 15.06.2021 / MD
|
||||
' Version Date / Editor: 15.06.2021 / MD
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub InitializeExportWinLineDoc_CreateVar()
|
||||
|
||||
|
||||
'Storage for custom fields on LEVEL 0
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 90, "1", 64 'Erstellt wer / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 91, "6", 16 'Erstellt wann / Datum mit Zeit
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 92, "1", 64 'Geändert wer / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 93, "6", 16 'Geändert wann / Datum mit Zeit
|
||||
|
||||
'----------------------------------------------------------------------------------------------------------
|
||||
|
||||
'Storage for custom fields on LEVEL 1
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 0, "2", 25 'GUID / Integer
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 1, "2", 3 'Aktiv / Integer (bool)
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 2, "1", 512 'Beschreibung / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 3, "31", 4 'Mandant / ComboBox
|
||||
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 4, "1", 128 'WinLine Variable 1 / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 5, "1", 128 'WinLine Variable 2 / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 6, "1", 128 'WinLine Variable 3 / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 7, "1", 128 'WinLine Variable 4 / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 8, "1", 128 'WinLine Variable 5 / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 9, "1", 128 'WinLine Variable 6 / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 10,"1", 128 'WinLine Variable 7 / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 11,"1", 128 'WinLine Variable 8 / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 12,"1", 128 'WinLine Variable 9 / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 13,"1", 128 'WinLine Variable 10 / String
|
||||
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 14,"31", 50 'Call Makro pre Export 1 / ComboBox
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 15,"31", 50 'Call Makro pre Export 2 / ComboBox
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 16,"31", 50 'Call Makro pre Export 3 / ComboBox
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 17,"31", 50 'Call Makro pre Export 4 / ComboBox
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 18,"31", 50 'Call Makro pre Export 5 / ComboBox
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 19,"31", 50 'Call Makro pre Export 6 / ComboBox
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 20,"31", 50 'Call Makro pre Export 7 / ComboBox
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 21,"31", 50 'Call Makro pre Export 8 / ComboBox
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 22,"31", 50 'Call Makro pre Export 9 / ComboBox
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 23,"31", 50 'Call Makro pre Export 10 / ComboBox
|
||||
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 24,"1", 256 'Export Pfad / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 25,"1", 256 'Export Dateiname / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 26,"1", 256 'Export Dateiname Vorschau / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 27,"2", 3 'Export Dateiendung / Integer
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 28,"2", 3 'Export Versionierung / Integer
|
||||
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 99,"1", 255 'GUID / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 98,"1", 255 'TabelCounter / String
|
||||
|
||||
'----------------------------------------------------------------------------------------------------------
|
||||
|
||||
'Storage for custom fields on LEVEL 2
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 50,"2", 25 'GUID / Integer
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 51,"2", 3 'Aktiv / Integer (bool)
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 52,"1", 512 'Beschreibung / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 53,"31", 4 'Mandant / ComboBox
|
||||
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 54,"31", 16 'Eintragstyp / ComboBox
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 55, "1",512 'Platzhalter / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 56,"31", 16 'Datentyp / ComboBox
|
||||
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 57, "1",512 'Text-Wert / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 58, "2", 64 'Integer-Wert / Zahl ohne Nachkommastellen
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 59, "4", 64 'Double-Wert / Zahl mit Nachkommastellen
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 60, "6", 64 'Date-Wert / Datum mit Zeit
|
||||
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 97,"1", 255 'GUID / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 96,"1", 255 'TabelCounter / String
|
||||
|
||||
'----------------------------------------------------------------------------------------------------------
|
||||
|
||||
'Storage for custom fields on LEVEL 3
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 80,"1", 512 'Standard Modul Pfad / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 81,"1", 512 'Export-WinLineDoc Modul Pfad / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 82,"1", 50 'WebServiceUser / String
|
||||
CWLCurrentWindow.ActiveWindow.Vars.CreateVar 495, 89,"1",4000 '<Blank> / String
|
||||
|
||||
End Sub
|
||||
|
||||
'Create Var
|
||||
'Type Bedeutung
|
||||
'1 Textvariable (Länge wählbar)
|
||||
'2 Zahl ohne Nachkommastellen (Integer)
|
||||
'4 Zahl mit Nachkommastellen (Double)
|
||||
'6 Datum mit Zeit
|
||||
273
archive/Export-WinLineDoc/Modules/NewExportWinLineDoc_Record.vbm
Normal file
273
archive/Export-WinLineDoc/Modules/NewExportWinLineDoc_Record.vbm
Normal file
@@ -0,0 +1,273 @@
|
||||
' NewExportWinLineDoc_Record
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Funktion startet die Neuanlage eines Datensatzes oder beendet diese vorzeitig (ohne zu speichern).
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
' Parameter 2 (ABORT) = "True" übergeben, wenn die Neuanlage abgebrochen werden soll.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 15.07.2021 / MK
|
||||
' Version Date / Editor: 15.07.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Function NewExportWinLineDoc_Record(LEVEL,ABORT)
|
||||
|
||||
If (((LEVEL = 1) or (LEVEL = "1")) and (ABORT = False)) Then
|
||||
|
||||
'Set Grid vars to empty
|
||||
LEVEL1_GRID_CURRENT_ROW = 0
|
||||
LEVEL1_GRID_CURRENT_GUID = 0
|
||||
LEVEL1_GRID_CURRENT_AKTIV = 0
|
||||
LEVEL1_GRID_CURRENT_Beschreibung = 0
|
||||
LEVEL1_GRID_CURRENT_Mandant = 0
|
||||
|
||||
'Set Grid cols inactive
|
||||
LEVEL1_Grid.SetColumnReadOnly LEVEL1_GRID_COLUMN_GUID, true, true
|
||||
LEVEL1_Grid.SetColumnReadOnly LEVEL1_GRID_COLUMN_AKTIV, true, true
|
||||
LEVEL1_Grid.SetColumnReadOnly LEVEL1_GRID_COLUMN_BESCHREIBUNG, true, true
|
||||
LEVEL1_Grid.SetColumnReadOnly LEVEL1_GRID_COLUMN_MANDANT, true, true
|
||||
|
||||
'Disable all input controls..
|
||||
DisableExportWinLineDoc_InputControls CURRENT_LEVEL,"static"
|
||||
|
||||
'And enable them again
|
||||
EnableExportWinLineDoc_InputControls CURRENT_LEVEL,"static"
|
||||
|
||||
'-------------------------------------------------------
|
||||
|
||||
'Set controls with default values, if there are no old values...
|
||||
'Old values (ScreenContents) is used for a profile copy
|
||||
|
||||
'Always set new profiles to inactive state
|
||||
LEVEL1_CHK_Aktiv.Contents = ""
|
||||
LEVEL1_CHK_Aktiv.Contents = "0"
|
||||
|
||||
If (LEVEL1_TXT_Beschreibung.ScreenContents = "") Then
|
||||
LEVEL1_TXT_Beschreibung.Contents = "Neues Profil"
|
||||
Else
|
||||
LEVEL1_TXT_Beschreibung.Contents = "Kopie von " & LEVEL1_TXT_Beschreibung.ScreenContents
|
||||
End if
|
||||
If (LEVEL1_TXT_Mandant.ScreenContents = "") Then
|
||||
LEVEL1_TXT_Mandant.Contents = "ALL"
|
||||
End if
|
||||
|
||||
If (LEVEL1_TXT_CallMakroPreExport1.ScreenContents = "") Then
|
||||
LEVEL1_TXT_CallMakroPreExport1.Contents = "<KEIN MAKRO>"
|
||||
End if
|
||||
If (LEVEL1_TXT_CallMakroPreExport2.ScreenContents = "") Then
|
||||
LEVEL1_TXT_CallMakroPreExport2.Contents = "<KEIN MAKRO>"
|
||||
End if
|
||||
If (LEVEL1_TXT_CallMakroPreExport3.ScreenContents = "") Then
|
||||
LEVEL1_TXT_CallMakroPreExport3.Contents = "<KEIN MAKRO>"
|
||||
End if
|
||||
If (LEVEL1_TXT_CallMakroPreExport4.ScreenContents = "") Then
|
||||
LEVEL1_TXT_CallMakroPreExport4.Contents = "<KEIN MAKRO>"
|
||||
End if
|
||||
If (LEVEL1_TXT_CallMakroPreExport5.ScreenContents = "") Then
|
||||
LEVEL1_TXT_CallMakroPreExport5.Contents = "<KEIN MAKRO>"
|
||||
End if
|
||||
If (LEVEL1_TXT_CallMakroPreExport6.ScreenContents = "") Then
|
||||
LEVEL1_TXT_CallMakroPreExport6.Contents = "<KEIN MAKRO>"
|
||||
End if
|
||||
If (LEVEL1_TXT_CallMakroPreExport7.ScreenContents = "") Then
|
||||
LEVEL1_TXT_CallMakroPreExport7.Contents = "<KEIN MAKRO>"
|
||||
End if
|
||||
If (LEVEL1_TXT_CallMakroPreExport8.ScreenContents = "") Then
|
||||
LEVEL1_TXT_CallMakroPreExport8.Contents = "<KEIN MAKRO>"
|
||||
End if
|
||||
If (LEVEL1_TXT_CallMakroPreExport9.ScreenContents = "") Then
|
||||
LEVEL1_TXT_CallMakroPreExport9.Contents = "<KEIN MAKRO>"
|
||||
End if
|
||||
If (LEVEL1_TXT_CallMakroPreExport10.ScreenContents = "") Then
|
||||
LEVEL1_TXT_CallMakroPreExport10.Contents = "<KEIN MAKRO>"
|
||||
End if
|
||||
|
||||
If (LEVEL1_TXT_ExportPfad.ScreenContents = "") Then
|
||||
LEVEL1_TXT_ExportPfad.Contents = "%EXPORTPATH%"
|
||||
End if
|
||||
If (LEVEL1_TXT_ExportDateiname.ScreenContents = "") Then
|
||||
LEVEL1_TXT_ExportDateiname.Contents = "%MandantenNr%-%KontoNr%-%Belegnummer%-%Laufnummer%"
|
||||
End if
|
||||
If (LEVEL1_TXT_ExportDateinameVorschau.ScreenContents = "") Then
|
||||
LEVEL1_TXT_ExportDateinameVorschau.Contents = "%MandantenNr%-%KontoNr%-%Belegnummer%-%Laufnummer%"
|
||||
End if
|
||||
If (LEVEL1_TXT_ExportDateiendung.ScreenContents = "") Then
|
||||
LEVEL1_TXT_ExportDateiendung.Contents = "5"
|
||||
End if
|
||||
If (LEVEL1_TXT_ExportVersionierung.ScreenContents = "") Then
|
||||
LEVEL1_TXT_ExportVersionierung.Contents = "9"
|
||||
End if
|
||||
|
||||
'...and set focus to every field once
|
||||
SetExportWinLineDoc_FocusToRequiredFields CURRENT_LEVEL
|
||||
|
||||
'Reset counter, to force SetFiledFocus on next switch
|
||||
LEVEL1_GRID_CALLCOUNT = 0
|
||||
'-------------------------------------------------------
|
||||
|
||||
'Disable ribbon and menu buttons
|
||||
DisableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"static"
|
||||
|
||||
'To let the save sub knwo, it a new line!
|
||||
NewExportWinLineDoc_Record = -1
|
||||
|
||||
'---------------------------------------------------------------------------------------
|
||||
'***************************************************************************************
|
||||
'---------------------------------------------------------------------------------------
|
||||
|
||||
ElseIf (((LEVEL = 2) or (LEVEL = "2")) and (ABORT = False)) Then
|
||||
|
||||
'Set Grid vars to empty
|
||||
LEVEL2_GRID_CURRENT_ROW = 0
|
||||
LEVEL2_GRID_CURRENT_GUID = 0
|
||||
LEVEL2_GRID_CURRENT_AKTIV = 0
|
||||
LEVEL2_GRID_CURRENT_Beschreibung = 0
|
||||
LEVEL2_GRID_CURRENT_Mandant = 0
|
||||
|
||||
'Set Grid cols inactive
|
||||
LEVEL2_Grid.SetColumnReadOnly LEVEL2_GRID_COLUMN_GUID, true, true
|
||||
LEVEL2_Grid.SetColumnReadOnly LEVEL2_GRID_COLUMN_AKTIV, true, true
|
||||
LEVEL2_Grid.SetColumnReadOnly LEVEL2_GRID_COLUMN_BESCHREIBUNG, true, true
|
||||
LEVEL2_Grid.SetColumnReadOnly LEVEL2_GRID_COLUMN_MANDANT, true, true
|
||||
|
||||
'Disable all input controls..
|
||||
DisableExportWinLineDoc_InputControls CURRENT_LEVEL,"static"
|
||||
|
||||
'And enable them again
|
||||
EnableExportWinLineDoc_InputControls CURRENT_LEVEL,"static"
|
||||
|
||||
'-------------------------------------------------------
|
||||
|
||||
'Set controls with default values, if there are no old values...
|
||||
'Old values (ScreenContents) is used for a profile copy
|
||||
|
||||
'Always set new profiles to inactive state
|
||||
LEVEL2_CHK_Aktiv.Contents = ""
|
||||
LEVEL2_CHK_Aktiv.Contents = "0"
|
||||
|
||||
If (LEVEL2_TXT_Beschreibung.ScreenContents = "") Then
|
||||
LEVEL2_TXT_Beschreibung.Contents = "Neues Profil"
|
||||
Else
|
||||
LEVEL2_TXT_Beschreibung.Contents = "Kopie von " & LEVEL2_TXT_Beschreibung.ScreenContents
|
||||
End if
|
||||
If (LEVEL2_TXT_Mandant.ScreenContents = "") Then
|
||||
LEVEL2_TXT_Mandant.Contents = "ALL"
|
||||
End if
|
||||
|
||||
If (LEVEL2_TXT_Eintragstyp.ScreenContents = "") Then
|
||||
LEVEL2_TXT_Eintragstyp.Contents = "CUSTOM_VARIABLE"
|
||||
End if
|
||||
If (LEVEL2_TXT_Platzhalter.ScreenContents = "") Then
|
||||
LEVEL2_TXT_Platzhalter.Contents = "%PLATZHALTER%"
|
||||
End if
|
||||
If (LEVEL2_TXT_Datentyp.ScreenContents = "") Then
|
||||
LEVEL2_TXT_Datentyp.Contents = "TEXT"
|
||||
End if
|
||||
|
||||
IF (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Text", vbTextCompare ) > 0) Then
|
||||
If (LEVEL2_TXT_Text_Wert.ScreenContents = "") Then
|
||||
LEVEL2_TXT_Text_Wert.Contents = "c:\WinLine\Dokumentablage"
|
||||
End if
|
||||
End if
|
||||
If (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Integer", vbTextCompare ) > 0) Then
|
||||
If (LEVEL2_TXT_Integer_Wert.ScreenContents = "") Then
|
||||
LEVEL2_TXT_Integer_Wert.Contents = 0
|
||||
End if
|
||||
End if
|
||||
If (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Double", vbTextCompare ) > 0) Then
|
||||
If (LEVEL2_TXT_Double_Wert.ScreenContents = "") Then
|
||||
LEVEL2_TXT_Double_Wert.Contents = 0.0
|
||||
End if
|
||||
End if
|
||||
If (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Date", vbTextCompare ) > 0) Then
|
||||
If (LEVEL2_TXT_Date_Wert.ScreenContents = "") Then
|
||||
LEVEL2_TXT_Date_Wert.Contents = "01.01.1970"
|
||||
End if
|
||||
End if
|
||||
|
||||
'...and set focus to every field once
|
||||
SetExportWinLineDoc_FocusToRequiredFields CURRENT_LEVEL
|
||||
|
||||
'SPECIAL: set data type fields depending on selcted type on/off
|
||||
DisableExportWinLineDoc_InputControls CURRENT_LEVEL,"dynamic"
|
||||
|
||||
'Reset counter, to force SetFiledFocus on next switch
|
||||
LEVEL2_GRID_CALLCOUNT = 0
|
||||
'-------------------------------------------------------
|
||||
|
||||
'Disable ribbon and menu buttons
|
||||
DisableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"static"
|
||||
|
||||
'To let the save sub knwo, it a new line!
|
||||
NewExportWinLineDoc_Record = -1
|
||||
|
||||
'If new line was aborted on tab / level 1
|
||||
ElseIf ((LEVEL = 1) or (LEVEL = "1") and (ABORT = True)) Then
|
||||
|
||||
LEVEL1_Grid.SetColumnReadOnly LEVEL1_GRID_COLUMN_GUID, False, False
|
||||
LEVEL1_Grid.SetColumnReadOnly LEVEL1_GRID_COLUMN_AKTIV, False, False
|
||||
LEVEL1_Grid.SetColumnReadOnly LEVEL1_GRID_COLUMN_BESCHREIBUNG, False, False
|
||||
LEVEL1_Grid.SetColumnReadOnly LEVEL1_GRID_COLUMN_MANDANT, False, False
|
||||
|
||||
'Set Grid vars to empty
|
||||
LEVEL1_GRID_CURRENT_ROW = 0
|
||||
LEVEL1_GRID_CURRENT_GUID = 0
|
||||
LEVEL1_GRID_CURRENT_AKTIV = 0
|
||||
LEVEL1_GRID_CURRENT_Beschreibung = 0
|
||||
LEVEL1_GRID_CURRENT_Mandant = 0
|
||||
|
||||
'And enable tabs again
|
||||
EnableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"static"
|
||||
EnableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"dynamic"
|
||||
|
||||
'Focus Grid and line again, wil trigger to set LEVEL1_GRID_CURRENT_GUID again
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID,LEVEL1_GRID_ID
|
||||
|
||||
'After reloading, go through all fields again
|
||||
If ((LEVEL1_GRID_CURRENT_GUID > 0) and (LEVEL1_GRID_CURRENT_ROW > 0)) Then
|
||||
|
||||
SetExportWinLineDoc_FocusToRequiredFields CURRENT_LEVEL
|
||||
|
||||
End if
|
||||
|
||||
'Return GUID from selected line
|
||||
NewExportWinLineDoc_Record = LEVEL1_GRID_CURRENT_GUID
|
||||
|
||||
'If new line was aborted on tab / level 2
|
||||
ElseIf ((LEVEL = 2) or (LEVEL = "2") and (ABORT = True)) Then
|
||||
|
||||
LEVEL2_Grid.SetColumnReadOnly LEVEL2_GRID_COLUMN_GUID, False, False
|
||||
LEVEL2_Grid.SetColumnReadOnly LEVEL2_GRID_COLUMN_AKTIV, False, False
|
||||
LEVEL2_Grid.SetColumnReadOnly LEVEL2_GRID_COLUMN_BESCHREIBUNG, False, False
|
||||
LEVEL2_Grid.SetColumnReadOnly LEVEL2_GRID_COLUMN_MANDANT, False, False
|
||||
|
||||
LEVEL2_GRID_CURRENT_ROW = 0
|
||||
LEVEL2_GRID_CURRENT_GUID = 0
|
||||
LEVEL2_GRID_CURRENT_AKTIV = 0
|
||||
LEVEL2_GRID_CURRENT_Beschreibung = 0
|
||||
LEVEL2_GRID_CURRENT_Mandant = 0
|
||||
|
||||
'And enable tabs again
|
||||
EnableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"static"
|
||||
EnableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"dynamic"
|
||||
|
||||
'Focus Grid and line again, wil trigger to set LEVEL2_GRID_CURRENT_GUID again
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID,LEVEL2_GRID_ID
|
||||
|
||||
'After reloading, go through all fields again
|
||||
If ((LEVEL2_GRID_CURRENT_GUID > 0) and (LEVEL2_GRID_CURRENT_ROW > 0)) Then
|
||||
|
||||
SetExportWinLineDoc_FocusToRequiredFields CURRENT_LEVEL
|
||||
|
||||
End if
|
||||
|
||||
'Return GUID from selected line
|
||||
NewExportWinLineDoc_Record = LEVEL2_GRID_CURRENT_GUID
|
||||
|
||||
End If
|
||||
|
||||
End Function
|
||||
1229
archive/Export-WinLineDoc/Modules/SaveExportWinLineDoc_Record.vbm
Normal file
1229
archive/Export-WinLineDoc/Modules/SaveExportWinLineDoc_Record.vbm
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,166 @@
|
||||
' SetExportWinLineDoc_ComboBoxControls
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Funktion liefert Werte, um Auswahlboxen zu füllen.
|
||||
' Parameter 1 (CTRLType)= Name oder Typ des Controls welches gefüllt werden soll.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 16.07.2021 / MK
|
||||
' Version Date / Editor: 16.07.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Function SetExportWinLineDoc_ComboBoxControls(CMBType)
|
||||
|
||||
if (CMBType = "Mandant") Then
|
||||
|
||||
Set SQLResult_Mandators = Conn.Select(SQLQuery_Mandators)
|
||||
If (SQLResult_Mandators.RowCount) > 0 Then
|
||||
|
||||
Mandators = 0
|
||||
Mandators = "ALL :Alle Mandanten;"
|
||||
|
||||
'----------------------------------------------------
|
||||
'Inital Value before "NextRecord"
|
||||
Mandators = Mandators & SQLResult_Mandators.value("c000")
|
||||
|
||||
For Loop1 = Len(SQLResult_Mandators.value("c000"))+1 To 3
|
||||
|
||||
Mandators = Mandators & " "
|
||||
|
||||
Next
|
||||
|
||||
Mandators = Mandators & ":" & SQLResult_Mandators.value("c003") & ";"
|
||||
'----------------------------------------------------
|
||||
|
||||
Do
|
||||
'Loop for every combobox value
|
||||
If (SQLResult_Mandators.NextRecord = True) Then
|
||||
Mandators = Mandators & SQLResult_Mandators.value("c000")
|
||||
|
||||
'Inital Value before "NextRecord"
|
||||
For Loop2 = Len(SQLResult_Mandators.value("c000"))+1 To 3
|
||||
Mandators = Mandators & " "
|
||||
|
||||
Next
|
||||
|
||||
Mandators = Mandators & ":" & SQLResult_Mandators.value("c003") & ";"
|
||||
Else
|
||||
'To remove last ";"
|
||||
Mandators = LEFT(Mandators, Len(Mandators)-1)
|
||||
Exit Do
|
||||
|
||||
End If
|
||||
Loop
|
||||
|
||||
Else
|
||||
Mandators = "ALL :Alle Mandanten"
|
||||
|
||||
End If
|
||||
|
||||
SetExportWinLineDoc_ComboBoxControls = Mandators
|
||||
|
||||
ElseIf (CMBType = "ProgramMakros") Then
|
||||
|
||||
Set SQLResult_ProgramMakros = Conn.Select(SQLQuery_ProgramMakros)
|
||||
If (SQLResult_ProgramMakros.RowCount) > 0 Then
|
||||
|
||||
ProgramMakros = ""
|
||||
|
||||
'----------------------------------------------------
|
||||
'Inital Value before "NextRecord"
|
||||
|
||||
ProgramMakro = ""
|
||||
ProgramMakro = SQLResult_ProgramMakros.value("c000")
|
||||
ProgramMakro = Split(ProgramMakro,"@")
|
||||
|
||||
ProgramMakros = ProgramMakros & ProgramMakro(0)
|
||||
|
||||
For Loop1 = Len(SQLResult_ProgramMakros.value("c000"))+1 To 3
|
||||
|
||||
ProgramMakros = ProgramMakros & " "
|
||||
|
||||
Next
|
||||
|
||||
ProgramMakros = ProgramMakros & ":;"
|
||||
'----------------------------------------------------
|
||||
|
||||
Do
|
||||
'Loop for every combobox value
|
||||
If (SQLResult_ProgramMakros.NextRecord = True) Then
|
||||
ProgramMakro = ""
|
||||
ProgramMakro = SQLResult_ProgramMakros.value("c000")
|
||||
ProgramMakro = Split(ProgramMakro,"@")
|
||||
|
||||
ProgramMakros = ProgramMakros & ProgramMakro(0)
|
||||
|
||||
'Inital Value before "NextRecord"
|
||||
For Loop2 = Len(SQLResult_ProgramMakros.value("c000"))+1 To 3
|
||||
ProgramMakros = ProgramMakros & " "
|
||||
|
||||
Next
|
||||
|
||||
ProgramMakros = ProgramMakros & ":;"
|
||||
Else
|
||||
'To remove last ";"
|
||||
ProgramMakros = LEFT(ProgramMakros, Len(ProgramMakros)-1)
|
||||
Exit Do
|
||||
|
||||
End If
|
||||
Loop
|
||||
|
||||
Else
|
||||
ProgramMakros = "<KEIN MAKRO>:"
|
||||
|
||||
End If
|
||||
|
||||
SetExportWinLineDoc_ComboBoxControls = ProgramMakros
|
||||
|
||||
ElseIf (CMBType = "Dateiendung") Then
|
||||
|
||||
Dateiendungen = ""
|
||||
Dateiendungen = Dateiendungen & "0:Export als SPL - WinLine SPOOL-Format;"
|
||||
Dateiendungen = Dateiendungen & "1:Export als MHT - Multipurpose Internet Mail Extension HTML Datei;"
|
||||
Dateiendungen = Dateiendungen & "4:Export als SPL - WinLine SPOOL-Format Version 2.0 (altes Format);"
|
||||
Dateiendungen = Dateiendungen & "5:Export als PDF - Portable Document Format - Adobe PDF;"
|
||||
Dateiendungen = Dateiendungen & "6:Export als rtf/doc - WordRTF"
|
||||
|
||||
SetExportWinLineDoc_ComboBoxControls = Dateiendungen
|
||||
|
||||
ElseIf (CMBType = "Versionierung") Then
|
||||
|
||||
Versionierung = ""
|
||||
Versionierung = Versionierung & "0:Abbruch, wenn Datei bereits vorhanden;"
|
||||
Versionierung = Versionierung & "1:Überschreibe, wenn Datei bereits vorhanden;"
|
||||
Versionierung = Versionierung & "2:Zusammenführen, wenn Datei bereits vorhanden (nur PDF);"
|
||||
Versionierung = Versionierung & "9:Versioniere, wenn Datei bereits vorhanden;"
|
||||
|
||||
SetExportWinLineDoc_ComboBoxControls = Versionierung
|
||||
|
||||
ElseIf (CMBType = "Eintragstyp") Then
|
||||
|
||||
Eintragstyp = ""
|
||||
Eintragstyp = Eintragstyp & "CUSTOM_VARIABLE:"
|
||||
|
||||
SetExportWinLineDoc_ComboBoxControls = Eintragstyp
|
||||
|
||||
ElseIf (CMBType = "Datentyp") Then
|
||||
|
||||
Datentyp = ""
|
||||
Datentyp = Datentyp & "TEXT:;"
|
||||
Datentyp = Datentyp & "INTEGER:;"
|
||||
Datentyp = Datentyp & "DOUBLE:;"
|
||||
Datentyp = Datentyp & "DATE:"
|
||||
|
||||
SetExportWinLineDoc_ComboBoxControls = Datentyp
|
||||
|
||||
Else
|
||||
|
||||
SetExportWinLineDoc_ComboBoxControls = "<ERROR>"
|
||||
|
||||
End if
|
||||
|
||||
End Function
|
||||
@@ -0,0 +1,60 @@
|
||||
' SetExportWinLineDoc_FocusToRequiredFields
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine geht einmal durch sämtliche MUSS-Felder durch, damit ein User nicht manuell durchklicken muss.
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 30.06.2021 / MK
|
||||
' Version Date / Editor: 30.06.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub SetExportWinLineDoc_FocusToRequiredFields(LEVEL)
|
||||
|
||||
If (LEVEL = 1) or (LEVEL = "1") Then
|
||||
|
||||
'As long focusing fields, prevent someone interrups by switching tabs/levels
|
||||
LEVEL1_TAB_LEVEL1_TO_LEVEL1.Active = False
|
||||
LEVEL1_TAB_LEVEL1_TO_LEVEL2.Active = False
|
||||
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL1_GRID_ID
|
||||
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL1_TXT_ExportVersionierung_ID
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL1_TXT_ExportDateiendung_ID
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL1_TXT_ExportDateinameVorschau_ID
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL1_TXT_ExportDateiname_ID
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL1_TXT_ExportPfad_ID
|
||||
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL1_TXT_Mandant_ID
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL1_TXT_Beschreibung_ID
|
||||
|
||||
LEVEL1_TAB_LEVEL1_TO_LEVEL1.Active = True
|
||||
LEVEL1_TAB_LEVEL1_TO_LEVEL2.Active = True
|
||||
|
||||
'--------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
ElseIf (LEVEL = 2) or (LEVEL = "2") Then
|
||||
|
||||
'As long focusing fields, prevent someone interrups by switching tabs/levels
|
||||
LEVEL2_TAB_LEVEL2_TO_LEVEL1.Active = False
|
||||
LEVEL2_TAB_LEVEL2_TO_LEVEL2.Active = False
|
||||
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL2_GRID_ID
|
||||
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL2_TXT_Eintragstyp_ID
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL2_TXT_Platzhalter_ID
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL2_TXT_Datentyp_ID
|
||||
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL2_TXT_Mandant_ID
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID, LEVEL2_TXT_Beschreibung_ID
|
||||
|
||||
LEVEL2_TAB_LEVEL2_TO_LEVEL1.Active = True
|
||||
LEVEL2_TAB_LEVEL2_TO_LEVEL2.Active = True
|
||||
|
||||
End if
|
||||
|
||||
End Sub
|
||||
@@ -0,0 +1,166 @@
|
||||
' SetExportWinLineDoc_InputControls
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine füllt Controls in der GUI (anhand zuvor gesetzter Zwischenvariablen):
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
' Parameter 2 (CTRLType)= "Static" setzt pauschal, "dynamic" setzt anhand anderer Laufzeitvariablen, oder "clear" leert die Felder.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 16.06.2021 / MK
|
||||
' Version Date / Editor: 16.06.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub SetExportWinLineDoc_InputControls(LEVEL,CTRLType)
|
||||
|
||||
If ((LEVEL = 1) or (LEVEL = "1")) and ((CTRLType = "dynamic") or (CTRLType = "static")) Then
|
||||
|
||||
'Very important to set a checkbox by "" at first
|
||||
LEVEL1_CHK_Aktiv.Contents = ""
|
||||
LEVEL1_CHK_Aktiv.Contents = cstr(LEVEL1_CHK_Aktiv_DBValue)
|
||||
LEVEL1_TXT_Beschreibung.Contents = cstr(LEVEL1_TXT_Beschreibung_DBValue)
|
||||
LEVEL1_TXT_Mandant.Contents = cstr(LEVEL1_TXT_Mandant_DBValue)
|
||||
|
||||
LEVEL1_TXT_WinLineVariable1.Contents = cstr(LEVEL1_TXT_WinLineVariable1_DBValue)
|
||||
LEVEL1_TXT_WinLineVariable2.Contents = cstr(LEVEL1_TXT_WinLineVariable2_DBValue)
|
||||
LEVEL1_TXT_WinLineVariable3.Contents = cstr(LEVEL1_TXT_WinLineVariable3_DBValue)
|
||||
LEVEL1_TXT_WinLineVariable4.Contents = cstr(LEVEL1_TXT_WinLineVariable4_DBValue)
|
||||
LEVEL1_TXT_WinLineVariable5.Contents = cstr(LEVEL1_TXT_WinLineVariable5_DBValue)
|
||||
LEVEL1_TXT_WinLineVariable6.Contents = cstr(LEVEL1_TXT_WinLineVariable6_DBValue)
|
||||
LEVEL1_TXT_WinLineVariable7.Contents = cstr(LEVEL1_TXT_WinLineVariable7_DBValue)
|
||||
LEVEL1_TXT_WinLineVariable8.Contents = cstr(LEVEL1_TXT_WinLineVariable8_DBValue)
|
||||
LEVEL1_TXT_WinLineVariable9.Contents = cstr(LEVEL1_TXT_WinLineVariable9_DBValue)
|
||||
LEVEL1_TXT_WinLineVariable10.Contents = cstr(LEVEL1_TXT_WinLineVariable10_DBValue)
|
||||
|
||||
LEVEL1_TXT_CallMakroPreExport1.contents = cstr(LEVEL1_TXT_CallMakroPreExport1_DBValue)
|
||||
LEVEL1_TXT_CallMakroPreExport2.contents = cstr(LEVEL1_TXT_CallMakroPreExport2_DBValue)
|
||||
LEVEL1_TXT_CallMakroPreExport3.contents = cstr(LEVEL1_TXT_CallMakroPreExport3_DBValue)
|
||||
LEVEL1_TXT_CallMakroPreExport4.contents = cstr(LEVEL1_TXT_CallMakroPreExport4_DBValue)
|
||||
LEVEL1_TXT_CallMakroPreExport5.contents = cstr(LEVEL1_TXT_CallMakroPreExport5_DBValue)
|
||||
LEVEL1_TXT_CallMakroPreExport6.contents = cstr(LEVEL1_TXT_CallMakroPreExport6_DBValue)
|
||||
LEVEL1_TXT_CallMakroPreExport7.contents = cstr(LEVEL1_TXT_CallMakroPreExport7_DBValue)
|
||||
LEVEL1_TXT_CallMakroPreExport8.contents = cstr(LEVEL1_TXT_CallMakroPreExport8_DBValue)
|
||||
LEVEL1_TXT_CallMakroPreExport9.contents = cstr(LEVEL1_TXT_CallMakroPreExport9_DBValue)
|
||||
LEVEL1_TXT_CallMakroPreExport10.contents = cstr(LEVEL1_TXT_CallMakroPreExport10_DBValue)
|
||||
|
||||
LEVEL1_TXT_ExportPfad.Contents = cstr(LEVEL1_TXT_ExportPfad_DBValue)
|
||||
LEVEL1_TXT_ExportDateiname.Contents = cstr(LEVEL1_TXT_ExportDateiname_DBValue)
|
||||
LEVEL1_TXT_ExportDateinameVorschau.Contents = cstr(LEVEL1_TXT_ExportDateinameVorschau_DBValue)
|
||||
LEVEL1_TXT_ExportDateiendung.Contents = cstr(LEVEL1_TXT_ExportDateiendung_DBValue)
|
||||
LEVEL1_TXT_ExportVersionierung.Contents = cstr(LEVEL1_TXT_ExportVersionierung_DBValue)
|
||||
|
||||
ElseIf ((LEVEL = 1) or (LEVEL = "1")) and (CTRLType = "clear") Then
|
||||
|
||||
'Very important to set a checkbox by "" at first
|
||||
LEVEL1_CHK_Aktiv.Contents = ""
|
||||
LEVEL1_CHK_Aktiv.Contents = cstr(0)
|
||||
LEVEL1_TXT_Beschreibung.Contents = cstr("")
|
||||
LEVEL1_TXT_Mandant.Contents = cstr("ALL")
|
||||
|
||||
LEVEL1_TXT_WinLineVariable1.Contents = cstr("")
|
||||
LEVEL1_TXT_WinLineVariable2.Contents = cstr("")
|
||||
LEVEL1_TXT_WinLineVariable3.Contents = cstr("")
|
||||
LEVEL1_TXT_WinLineVariable4.Contents = cstr("")
|
||||
LEVEL1_TXT_WinLineVariable5.Contents = cstr("")
|
||||
LEVEL1_TXT_WinLineVariable6.Contents = cstr("")
|
||||
LEVEL1_TXT_WinLineVariable7.Contents = cstr("")
|
||||
LEVEL1_TXT_WinLineVariable8.Contents = cstr("")
|
||||
LEVEL1_TXT_WinLineVariable9.Contents = cstr("")
|
||||
LEVEL1_TXT_WinLineVariable10.Contents = cstr("")
|
||||
|
||||
LEVEL1_TXT_CallMakroPreExport1.contents = cstr("<KEIN MAKRO>")
|
||||
LEVEL1_TXT_CallMakroPreExport2.contents = cstr("<KEIN MAKRO>")
|
||||
LEVEL1_TXT_CallMakroPreExport3.contents = cstr("<KEIN MAKRO>")
|
||||
LEVEL1_TXT_CallMakroPreExport4.contents = cstr("<KEIN MAKRO>")
|
||||
LEVEL1_TXT_CallMakroPreExport5.contents = cstr("<KEIN MAKRO>")
|
||||
LEVEL1_TXT_CallMakroPreExport6.contents = cstr("<KEIN MAKRO>")
|
||||
LEVEL1_TXT_CallMakroPreExport7.contents = cstr("<KEIN MAKRO>")
|
||||
LEVEL1_TXT_CallMakroPreExport8.contents = cstr("<KEIN MAKRO>")
|
||||
LEVEL1_TXT_CallMakroPreExport9.contents = cstr("<KEIN MAKRO>")
|
||||
LEVEL1_TXT_CallMakroPreExport10.contents = cstr("<KEIN MAKRO>")
|
||||
|
||||
LEVEL1_TXT_ExportPfad.Contents = cstr("")
|
||||
LEVEL1_TXT_ExportDateiname.Contents = cstr("")
|
||||
LEVEL1_TXT_ExportDateinameVorschau.Contents = cstr("")
|
||||
LEVEL1_TXT_ExportDateiendung.Contents = cstr("5")
|
||||
LEVEL1_TXT_ExportVersionierung.Contents = cstr("9")
|
||||
|
||||
'-------------------------------------------------------------------------------------------
|
||||
|
||||
ElseIf ((LEVEL = 2) or (LEVEL = "2")) and (CTRLType = "static") Then
|
||||
|
||||
'Very important to set a checkbox by "" at first
|
||||
LEVEL2_CHK_Aktiv.Contents = ""
|
||||
LEVEL2_CHK_Aktiv.Contents = cstr(LEVEL2_CHK_Aktiv_DBValue)
|
||||
LEVEL2_TXT_Beschreibung.Contents = cstr(LEVEL2_TXT_Beschreibung_DBValue)
|
||||
LEVEL2_TXT_Mandant.Contents = cstr(LEVEL2_TXT_Mandant_DBValue)
|
||||
|
||||
LEVEL2_TXT_Eintragstyp.Contents = cstr(LEVEL2_TXT_Eintragstyp_DBValue)
|
||||
LEVEL2_TXT_Platzhalter.Contents = cstr(LEVEL2_TXT_Platzhalter_DBValue)
|
||||
LEVEL2_TXT_Datentyp.Contents = cstr(LEVEL2_TXT_Datentyp_DBValue)
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Contents = cstr(LEVEL2_TXT_Text_Wert_DBValue)
|
||||
LEVEL2_TXT_Integer_Wert.Contents = CLng(LEVEL2_TXT_Integer_Wert_DBValue)
|
||||
LEVEL2_TXT_Double_Wert.Contents = cdbl(LEVEL2_TXT_Double_Wert_DBValue)
|
||||
|
||||
IF (LEVEL2_TXT_Date_Wert_DBValue <> "") Then
|
||||
LEVEL2_TXT_Date_Wert.Contents = cdate(LEVEL2_TXT_Date_Wert_DBValue)
|
||||
else
|
||||
LEVEL2_TXT_Date_Wert.Contents = "01.01.1970"
|
||||
end if
|
||||
|
||||
ElseIf ((LEVEL = 2) or (LEVEL = "2")) and (CTRLType = "clear") Then
|
||||
|
||||
LEVEL2_CHK_Aktiv.Contents = ""
|
||||
LEVEL2_CHK_Aktiv.Contents = cstr(0)
|
||||
LEVEL2_TXT_Beschreibung.Contents = cstr("")
|
||||
LEVEL2_TXT_Mandant.Contents = cstr("ALL")
|
||||
|
||||
LEVEL2_TXT_Eintragstyp.Contents = cstr("CUSTOM_VARIABLE")
|
||||
LEVEL2_TXT_Platzhalter.Contents = cstr("")
|
||||
LEVEL2_TXT_Datentyp.Contents = cstr("TEXT")
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Contents = cstr("")
|
||||
LEVEL2_TXT_Integer_Wert.Contents = CLng(0)
|
||||
LEVEL2_TXT_Double_Wert.Contents = cdbl(0.0)
|
||||
LEVEL2_TXT_Date_Wert.Contents = cdate("01.01.1970")
|
||||
|
||||
ElseIf ((LEVEL = 2) or (LEVEL = "2")) and (CTRLType = "dynamic") Then
|
||||
|
||||
LEVEL2_CHK_Aktiv.Contents = ""
|
||||
LEVEL2_CHK_Aktiv.Contents = cstr(LEVEL2_CHK_Aktiv_DBValue)
|
||||
LEVEL2_TXT_Beschreibung.Contents = cstr(LEVEL2_TXT_Beschreibung_DBValue)
|
||||
LEVEL2_TXT_Mandant.Contents = cstr(LEVEL2_TXT_Mandant_DBValue)
|
||||
|
||||
LEVEL2_TXT_Eintragstyp.Contents = cstr(LEVEL2_TXT_Eintragstyp_DBValue)
|
||||
LEVEL2_TXT_Platzhalter.Contents = cstr(LEVEL2_TXT_Platzhalter_DBValue)
|
||||
LEVEL2_TXT_Datentyp.Contents = cstr(LEVEL2_TXT_Datentyp_DBValue)
|
||||
|
||||
IF (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Text", vbTextCompare ) > 0) Then
|
||||
|
||||
LEVEL2_TXT_Text_Wert.Contents = cstr(LEVEL2_TXT_Text_Wert_DBValue)
|
||||
|
||||
ElseIf (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Integer", vbTextCompare ) > 0) Then
|
||||
|
||||
LEVEL2_TXT_Integer_Wert.Contents = CLng(LEVEL2_TXT_Integer_Wert_DBValue)
|
||||
|
||||
ElseIf (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Double", vbTextCompare ) > 0) Then
|
||||
|
||||
LEVEL2_TXT_Double_Wert.Contents = cdbl(LEVEL2_TXT_Double_Wert_DBValue)
|
||||
|
||||
ElseIf (Instr( 1, LEVEL2_TXT_Datentyp.screencontents, "Date", vbTextCompare ) > 0) Then
|
||||
|
||||
IF (LEVEL2_TXT_Date_Wert_DBValue <> "") Then
|
||||
LEVEL2_TXT_Date_Wert.Contents = cdate(LEVEL2_TXT_Date_Wert_DBValue)
|
||||
else
|
||||
LEVEL2_TXT_Date_Wert.Contents = "01.01.1970"
|
||||
end if
|
||||
|
||||
End if
|
||||
|
||||
End if
|
||||
|
||||
End Sub
|
||||
@@ -0,0 +1,101 @@
|
||||
' SetExportWinLineDoc_ReadOnlyControls
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine läd Daten für reine Anzeigefelder.
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 22.06.2021 / MD
|
||||
' Version Date / Editor: 22.06.2021 / MD
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub SetExportWinLineDoc_ReadOnlyControls(LEVEL)
|
||||
|
||||
If (LEVEL = 1) or (LEVEL = "1") Then
|
||||
|
||||
'Current selected line in grid 1
|
||||
IF (cint(LEVEL1_TXT_GUID_DBValue) > 0) Then
|
||||
LEVEL1_TXT_GUID.Contents = "GUID: " & cstr(LEVEL1_TXT_GUID_DBValue)
|
||||
Else
|
||||
LEVEL1_TXT_GUID.Contents = "GUID: <0>"
|
||||
End if
|
||||
|
||||
'Line Counter in grid 1
|
||||
If (LEVEL1_Grid.LineCount > 0) Then
|
||||
LEVEL1_TXT_TabelCounter.Contents = (Cstr(LEVEL1_Grid.LineCount) & " Zuordnungen gefunden")
|
||||
Else
|
||||
LEVEL1_TXT_TabelCounter.Contents = "Keine Zuordnungen gefunden"
|
||||
End if
|
||||
|
||||
ElseIf (LEVEL = 2) or (LEVEL = "2") Then
|
||||
|
||||
'Current selected line in grid 2
|
||||
IF (cint(LEVEL2_TXT_GUID_DBValue) > 0) Then
|
||||
LEVEL2_TXT_GUID.Contents = "GUID: " & cstr(LEVEL2_TXT_GUID_DBValue)
|
||||
Else
|
||||
LEVEL2_TXT_GUID.Contents = "GUID: <0>"
|
||||
End if
|
||||
|
||||
'Line Counter in grid 2
|
||||
If (LEVEL2_Grid.LineCount > 0) Then
|
||||
LEVEL2_TXT_TabelCounter.Contents = (Cstr(LEVEL2_Grid.LineCount) & " Zuordnungen gefunden")
|
||||
Else
|
||||
LEVEL2_TXT_TabelCounter.Contents = "Keine Zuordnungen gefunden"
|
||||
End if
|
||||
|
||||
ElseIf (LEVEL = 3) or (LEVEL = "3") Then
|
||||
|
||||
LEVEL3_TXT_Standard_Modul_Path.Contents = ModuleDefaultSourcePath
|
||||
LEVEL3_TXT_EWLD_Modul_Path.Contents = ModuleExportWinLineDocSourcePath
|
||||
LEVEL3_TXT_WebServiceUser.Contents = WebServiceUser
|
||||
LEVEL3_TXT_Blank.active = true
|
||||
LEVEL3_TXT_Blank.contents = " "
|
||||
|
||||
End if
|
||||
'------------------------------------------------------------------------------------------------------
|
||||
|
||||
'Definitely, does not matter tab / level 1 or 2 set these fields...
|
||||
If (((LEVEL = 1) or (LEVEL = "1")) and (LEVEL1_GRID_CURRENT_GUID > 0)) or (((LEVEL = 2) or (LEVEL = "2")) and (LEVEL2_GRID_CURRENT_GUID > 0)) Then
|
||||
|
||||
IF ((LEVEL0_TXT_Erstellt_wer_DBValue > empty) and (LEVEL0_TXT_Erstellt_wer_DBValue <> "")) Then
|
||||
LEVEL0_TXT_Erstellt_wer.Contents = cstr(LEVEL0_TXT_Erstellt_wer_DBValue)
|
||||
Else
|
||||
LEVEL0_TXT_Erstellt_wer.Contents = NULL
|
||||
End if
|
||||
'------------------------------------------------------------------------------------------------------
|
||||
|
||||
IF ((LEVEL0_TXT_Erstellt_wann_DBValue > empty) and (LEVEL0_TXT_Erstellt_wann_DBValue <> "")) Then
|
||||
LEVEL0_TXT_Erstellt_wann.Contents = cdate(LEVEL0_TXT_Erstellt_wann_DBValue)
|
||||
Else
|
||||
LEVEL0_TXT_Erstellt_wann.Contents = NULL
|
||||
End if
|
||||
'------------------------------------------------------------------------------------------------------
|
||||
|
||||
IF ((LEVEL0_TXT_Geaendert_wer_DBValue > empty) and (LEVEL0_TXT_Geaendert_wer_DBValue <> "")) Then
|
||||
LEVEL0_TXT_Geaendert_wer.Contents = cstr(LEVEL0_TXT_Geaendert_wer_DBValue)
|
||||
Else
|
||||
LEVEL0_TXT_Geaendert_wer.Contents = NULL
|
||||
End if
|
||||
'------------------------------------------------------------------------------------------------------
|
||||
|
||||
IF ((LEVEL0_TXT_Geaendert_wann_DBValue > empty) and (LEVEL0_TXT_Geaendert_wann_DBValue <> "")) Then
|
||||
LEVEL0_TXT_Geaendert_wann.Contents = cdate(LEVEL0_TXT_Geaendert_wann_DBValue)
|
||||
Else
|
||||
LEVEL0_TXT_Geaendert_wann.contents = NULL
|
||||
End if
|
||||
|
||||
'But if no valid line was selected...
|
||||
Elseif (LEVEL <> 3) and (LEVEL <> "3") Then
|
||||
|
||||
LEVEL0_TXT_Erstellt_wer.Contents = NULL
|
||||
LEVEL0_TXT_Erstellt_wann.Contents = NULL
|
||||
LEVEL0_TXT_Geaendert_wer.Contents = NULL
|
||||
LEVEL0_TXT_Geaendert_wann.contents = NULL
|
||||
|
||||
End if
|
||||
|
||||
End sub
|
||||
@@ -0,0 +1,168 @@
|
||||
' SetExportWinLineDoc_SQLData
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine füllt eine Tabelle (Grid) mit Daten
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
' Parameter 2 (BUTTON) = Die ID des betätigten Knopfs.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 15.07.2021 / MK
|
||||
' Version Date / Editor: 15.07.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub SetExportWinLineDoc_SQLData(LEVEL,BUTTON)
|
||||
|
||||
If (BUTTON = LEVEL3_BTN_Restore_Profiles_ID) Then
|
||||
|
||||
IF (FileSystemObject.FileExists(TemplateExportWinLineDoc_Profiles_File)) Then
|
||||
|
||||
Set SQLResult_Profiles = Conn.Select(SQLQuery_Profiles_Default)
|
||||
If (SQLResult_Profiles.RowCount) > 0 Then
|
||||
|
||||
MsgBoxResult = MsgBox ("Wenn Sie fortfahren, werden die Auslieferungsprofile gelöscht und neu angelegt!" & vbCrLf & vbCrLf & _
|
||||
"Änderungen an diesen gehen verloren!" & vbCrLf & vbCrLf & _
|
||||
"Der Vorgang kann NICHT Rückgängig gemacht werden!" & vbCrLf & vbCrLf & _
|
||||
"Möchten Sie fortfahren?",vbYesNo+vbCritical,DEFAULT_TITLE & " - ACHTUNG! ACHTUNG!")
|
||||
|
||||
If (MsgBoxResult = 6) Then
|
||||
|
||||
SQLResult_Profiles = Conn.ExecuteSQL(SQLDelete_Profiles)
|
||||
|
||||
LEVEL1_GRID_CURRENT_ROW = 0
|
||||
LEVEL1_GRID_CURRENT_GUID = 0
|
||||
LEVEL1_GRID_CURRENT_AKTIV = 0
|
||||
LEVEL1_GRID_CURRENT_Beschreibung = 0
|
||||
LEVEL1_GRID_CURRENT_Mandant = 0
|
||||
|
||||
If (SQLResult_Profiles = true) Then
|
||||
|
||||
'After the delete insert
|
||||
InsertExportWinLineDoc_SQLData LEVEL,TemplateExportWinLineDoc_Profiles_File
|
||||
|
||||
Else
|
||||
MsgBox "Der Löschvorgang ist fehlgeschlagen!" & vbCrLf & _
|
||||
"Bitte informieren Sie Ihren Administrator!" & vbCrLf & _
|
||||
"",vbOkayOnly+vbCritical,DEFAULT_TITLE & " - Fehler!"
|
||||
|
||||
SQLResult_Profiles = 0
|
||||
|
||||
End if
|
||||
|
||||
Else
|
||||
MsgBox "Der Vorgang wurde abgebrochen!",vbOkayOnly+vbInformation,DEFAULT_TITLE
|
||||
|
||||
End if
|
||||
|
||||
Else
|
||||
InsertExportWinLineDoc_SQLData LEVEL,TemplateExportWinLineDoc_Profiles_File
|
||||
|
||||
End If
|
||||
|
||||
Else
|
||||
MsgBox "Die Vorlagen-Datei wurde nicht gefunden!" & vbCrLf & vbCrLf &_
|
||||
TemplateExportWinLineDoc_Profiles_File & vbCrLf & _
|
||||
"",vbYesNo+vbCritical,DEFAULT_TITLE & " - Abbruch!"
|
||||
|
||||
End if
|
||||
|
||||
'------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
ElseIf (BUTTON = LEVEL3_BTN_Restore_Configs_ID) Then
|
||||
|
||||
Set SQLResult_Configs = Conn.Select(SQLQuery_Configs_Default)
|
||||
If (SQLResult_Configs.RowCount) > 0 Then
|
||||
|
||||
MsgBoxResult = MsgBox ("Wenn Sie fortfahren, werden die Auslieferungskonfigurationen gelöscht und neu angelegt!" & vbCrLf & vbCrLf & _
|
||||
"Änderungen an diesen gehen verloren!" & vbCrLf & vbCrLf & _
|
||||
"Der Vorgang kann NICHT Rückgängig gemacht werden!" & vbCrLf & vbCrLf & _
|
||||
"Möchten Sie fortfahren?",vbYesNo+vbCritical,DEFAULT_TITLE & " - ACHTUNG! ACHTUNG!")
|
||||
|
||||
If (MsgBoxResult = 6) Then
|
||||
|
||||
SQLResult_Configs = Conn.ExecuteSQL(SQLDelete_Configs)
|
||||
|
||||
LEVEL2_GRID_CURRENT_ROW = 0
|
||||
LEVEL2_GRID_CURRENT_GUID = 0
|
||||
LEVEL2_GRID_CURRENT_AKTIV = 0
|
||||
LEVEL2_GRID_CURRENT_Beschreibung = 0
|
||||
LEVEL2_GRID_CURRENT_Mandant = 0
|
||||
|
||||
If (SQLResult_Configs = true) Then
|
||||
|
||||
'After the delete insert
|
||||
InsertExportWinLineDoc_SQLData LEVEL,TemplateExportWinLineDoc_Configs_File
|
||||
|
||||
Else
|
||||
MsgBox "Der Löschvorgang ist fehlgeschlagen!" & vbCrLf & _
|
||||
"Bitte informieren Sie Ihren Administrator!" & vbCrLf & _
|
||||
"",vbOkayOnly+vbCritical,DEFAULT_TITLE & " - Fehler!"
|
||||
|
||||
SQLResult_Configs = 0
|
||||
|
||||
End if
|
||||
|
||||
Else
|
||||
MsgBox "Der Vorgang wurde abgebrochen!",vbOkayOnly+vbInformation,DEFAULT_TITLE
|
||||
|
||||
End if
|
||||
|
||||
Else
|
||||
InsertExportWinLineDoc_SQLData LEVEL,TemplateExportWinLineDoc_Configs_File
|
||||
|
||||
End If
|
||||
|
||||
Else
|
||||
MsgBox "Die Vorlagen-Datei wurde nicht gefunden!" & vbCrLf & vbCrLf &_
|
||||
TemplateExportWinLineDoc_Configs_File & vbCrLf & _
|
||||
"",vbYesNo+vbCritical,DEFAULT_TITLE & " - Abbruch!"
|
||||
|
||||
End if
|
||||
|
||||
End Sub
|
||||
|
||||
'------------------------------------------------------------------------------------------------------------------
|
||||
Private Sub InsertExportWinLineDoc_SQLData(LEVEL,FILE)
|
||||
|
||||
'Get file content of the sql script
|
||||
FileToRead.CharSet = "utf-8"
|
||||
FileToRead.Open
|
||||
FileToRead.LoadFromFile(File)
|
||||
FileToReadContents = FileToRead.ReadText()
|
||||
FileToRead.Close
|
||||
|
||||
SQLInsert = FileToReadContents
|
||||
|
||||
'Replace the default TB names
|
||||
SQLInsert = Replace(SQLInsert,"[dbo].[t650]",TBDD_EXPORT_WINLINEDOC_CONFIG)
|
||||
SQLInsert = Replace(SQLInsert,"[dbo].[t651]",TBDD_EXPORT_WINLINEDOC_PROFILE)
|
||||
|
||||
'Some magic OTRS cannot do
|
||||
SQLInsert = Replace(SQLInsert,vbCr,"")
|
||||
SQLInsert = Replace(SQLInsert,vbLf,"")
|
||||
SQLInsert = TRIM(SQLInsert)
|
||||
|
||||
'Execute Insert - remember that no "GO" order is supported
|
||||
SQLResult = Conn.ExecuteSQL(SQLInsert)
|
||||
|
||||
IF (SQLResult = True) Then
|
||||
msgbox "Die Wiederherstellung war erfolgreich!",vbOkayOnly+vbInformation,DEFAULT_TITLE
|
||||
|
||||
ElseIf (SQLResult = False) Then
|
||||
msgbox "Achtung, es ist ein Fehler aufgetreten!" & vbCrLf & _
|
||||
"Bitte informieren Sie Ihren Administrator!" & vbCrLf & _
|
||||
"",vbOkayOnly+vbCritical,DEFAULT_TITLE
|
||||
End if
|
||||
|
||||
IF (LEVEL = 1) Then
|
||||
SetExportWinLineDoc_TableContent LEVEL,LEVEL1_GRID_ID
|
||||
|
||||
ElseIf (LEVEL = 2) Then
|
||||
SetExportWinLineDoc_TableContent LEVEL,LEVEL2_GRID_ID
|
||||
|
||||
End if
|
||||
|
||||
End Sub
|
||||
@@ -0,0 +1,107 @@
|
||||
' SetExportWinLineDoc_TableContent
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine füllt eine Tabelle (Grid) mit Daten
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
' Parameter 2 (GRID) = Falls mehrere Grids auf einem Level vorkommen, kann über diesen Parameter nochmals unterscheiden werden.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 07.07.2021 / MK
|
||||
' Version Date / Editor: 07.07.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub SetExportWinLineDoc_TableContent(LEVEL,GRID)
|
||||
|
||||
If (LEVEL = 1) or (LEVEL = "1") Then
|
||||
|
||||
If (GRID = LEVEL1_GRID_ID) Then
|
||||
|
||||
LEVEL1_Grid.Clear
|
||||
LEVEL1_Grid.InitUserGrid
|
||||
LEVEL1_Grid.Header
|
||||
|
||||
Set SQLResult_Profiles = Conn.Select(SQLQuery_Profiles)
|
||||
If (SQLResult_Profiles.RowCount) > 0 Then
|
||||
|
||||
LEVEL1_Grid.IsRedraw = False
|
||||
|
||||
'Fill left Frame / Table
|
||||
If (SQLResult_Profiles.RowCount > 0) Then
|
||||
Do
|
||||
CWLCurrentWindow.ActiveWindow.Vars.Value(495,0) = cint(SQLResult_Profiles.value("u000"))
|
||||
CWLCurrentWindow.ActiveWindow.Vars.Value(495,1) = cstr(SQLResult_Profiles.value("u001"))
|
||||
CWLCurrentWindow.ActiveWindow.Vars.Value(495,2) = cstr(SQLResult_Profiles.value("u002"))
|
||||
CWLCurrentWindow.ActiveWindow.Vars.Value(495,3) = cstr(SQLResult_Profiles.value("u003"))
|
||||
|
||||
LEVEL1_Grid.AddLine()
|
||||
|
||||
'Trick it, because rowcount wont work
|
||||
If (SQLResult_Profiles.NextRecord = False) Then
|
||||
Exit Do
|
||||
End If
|
||||
Loop
|
||||
End If
|
||||
|
||||
LEVEL1_Grid.IsRedraw = True
|
||||
|
||||
'Show count down below the table
|
||||
LEVEL1_TXT_TabelCounter.Contents = (Cstr(LEVEL1_Grid.LineCount) & " Zuordnungen gefunden")
|
||||
|
||||
'Set focus for the fist call, so ribbon buttons will work well (eg. NEW)
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID,LEVEL1_GRID_ID
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
'------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
ElseIf (LEVEL = 2) or (LEVEL = "2") Then
|
||||
|
||||
If (GRID = LEVEL2_GRID_ID) Then
|
||||
|
||||
LEVEL2_Grid.Clear
|
||||
LEVEL2_Grid.InitUserGrid
|
||||
LEVEL2_Grid.Header
|
||||
|
||||
Set SQLResult_Configs = Conn.Select(SQLQuery_Configs)
|
||||
If (SQLResult_Configs.RowCount) > 0 Then
|
||||
|
||||
LEVEL2_Grid.IsRedraw = False
|
||||
|
||||
'Fill left Frame / Table
|
||||
If (SQLResult_Configs.RowCount > 0) Then
|
||||
Do
|
||||
CWLCurrentWindow.ActiveWindow.Vars.Value(495,50) = cint(SQLResult_Configs.value("u000"))
|
||||
CWLCurrentWindow.ActiveWindow.Vars.Value(495,51) = cstr(SQLResult_Configs.value("u001"))
|
||||
CWLCurrentWindow.ActiveWindow.Vars.Value(495,52) = cstr(SQLResult_Configs.value("u002"))
|
||||
CWLCurrentWindow.ActiveWindow.Vars.Value(495,53) = cstr(SQLResult_Configs.value("u003"))
|
||||
|
||||
LEVEL2_Grid.AddLine()
|
||||
|
||||
'Trick it, because rowcount wont work
|
||||
If (SQLResult_Configs.NextRecord = False) Then
|
||||
Exit Do
|
||||
End If
|
||||
Loop
|
||||
End If
|
||||
|
||||
LEVEL2_Grid.IsRedraw = True
|
||||
|
||||
'Show count down the table
|
||||
LEVEL2_TXT_TabelCounter.Contents = (Cstr(LEVEL2_Grid.LineCount) & " Zuordnungen gefunden")
|
||||
|
||||
'Set focus for the fist call, so ribbon buttons will work well (eg. NEW)
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID,LEVEL2_GRID_ID
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
End if
|
||||
|
||||
End Sub
|
||||
@@ -0,0 +1,45 @@
|
||||
' SetExportWinLineDoc_TableLayout
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine bereitet das Layout / die Spalten einer Tabelle (Grid) vor.
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
' Parameter 2 (GRID) = Falls mehrere Grids auf einem Level vorkommen, kann über diesen Parameter nochmals unterscheiden werden.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 05.07.2021 / MK
|
||||
' Version Date / Editor: 05.07.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub SetExportWinLineDoc_TableLayout(LEVEL,GRID)
|
||||
|
||||
If (LEVEL = 1) or (LEVEL = "1") Then
|
||||
|
||||
If (GRID = LEVEL1_GRID_ID) Then
|
||||
|
||||
LEVEL1_GRID_COLUMN_GUID = LEVEL1_Grid.AddColumn("GUID", "T21,GUID", "1","V",0,495,0, 0,scrtflag+sizeflag+hideflag)
|
||||
LEVEL1_GRID_COLUMN_AKTIV = LEVEL1_Grid.AddColumn("Aktiv", "T17,Aktiv", "l","V",0,495,1, 5,scrtflag+sizeflag+hideflag)
|
||||
LEVEL1_GRID_COLUMN_BESCHREIBUNG = LEVEL1_Grid.AddColumn("Beschreibung", "T21,Beschreibung", "1","V",0,495,2,40,scrtflag+sizeflag+hideflag)
|
||||
LEVEL1_GRID_COLUMN_MANDANT = LEVEL1_Grid.AddColumn("Mandant", "T21,Mandant", "1","V",0,495,3, 8,scrtflag+sizeflag+hideflag)
|
||||
|
||||
End If
|
||||
|
||||
'------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
ElseIf (LEVEL = 2) or (LEVEL = "2") Then
|
||||
|
||||
If (GRID = LEVEL2_GRID_ID) Then
|
||||
|
||||
LEVEL2_GRID_COLUMN_GUID = LEVEL2_Grid.AddColumn("GUID", "T21,GUID", "1","V",0,495,50, 0,scrtflag+sizeflag+hideflag)
|
||||
LEVEL2_GRID_COLUMN_AKTIV = LEVEL2_Grid.AddColumn("Aktiv", "T17,Aktiv", "l","V",0,495,51, 5,scrtflag+sizeflag+hideflag)
|
||||
LEVEL2_GRID_COLUMN_BESCHREIBUNG = LEVEL2_Grid.AddColumn("Beschreibung", "T21,Beschreibung", "1","V",0,495,52,40,scrtflag+sizeflag+hideflag)
|
||||
LEVEL2_GRID_COLUMN_MANDANT = LEVEL2_Grid.AddColumn("Mandant", "T21,Mandant", "1","V",0,495,53, 8,scrtflag+sizeflag+hideflag)
|
||||
|
||||
End If
|
||||
|
||||
End if
|
||||
|
||||
End Sub
|
||||
@@ -0,0 +1,53 @@
|
||||
' DD-INSERT_LANGBESCHINT_INTO_BELEGERFASSUNG
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine aktiviert unterschiedliche Showlevel.
|
||||
' Parameter 1 (LEVEL) = Das zu setzende Showlevel übergeben.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 15.07.2021 / MK
|
||||
' Version Date / Editor: 15.07.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub ShowExportWinLineDoc_Level(LEVEL)
|
||||
|
||||
If (LEVEL = 1) or (LEVEL = "1") Then
|
||||
|
||||
CWLCurrentWindow.ActiveWindow.SetShowLevel 1,1,True
|
||||
CWLCurrentWindow.ActiveWindow.SetShowLevel 2,2,False
|
||||
CWLCurrentWindow.ActiveWindow.SetShowLevel 3,3,False
|
||||
|
||||
CURRENT_LEVEL = 1
|
||||
|
||||
'Set focus, so ribbon buttons will work well (eg. NEW)
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID,LEVEL1_GRID_ID
|
||||
|
||||
ElseIf (LEVEL = 2) or (LEVEL = "2") Then
|
||||
|
||||
CWLCurrentWindow.ActiveWindow.SetShowLevel 2,2,True
|
||||
CWLCurrentWindow.ActiveWindow.SetShowLevel 1,1,False
|
||||
CWLCurrentWindow.ActiveWindow.SetShowLevel 3,3,False
|
||||
|
||||
CURRENT_LEVEL = 2
|
||||
|
||||
'Set focus, so ribbon buttons will work well (eg. NEW)
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID,LEVEL2_GRID_ID
|
||||
|
||||
ElseIf (LEVEL = 3) or (LEVEL = "3") Then
|
||||
|
||||
CWLCurrentWindow.ActiveWindow.SetShowLevel 3,3,True
|
||||
CWLCurrentWindow.ActiveWindow.SetShowLevel 0,0,False
|
||||
CWLCurrentWindow.ActiveWindow.SetShowLevel 1,1,False
|
||||
CWLCurrentWindow.ActiveWindow.SetShowLevel 2,2,False
|
||||
|
||||
CURRENT_LEVEL = 3
|
||||
|
||||
'MacroCommands.MSetFieldFocus MAIN_WINDOW_ID,LEVEL3_TXT_Blank_ID
|
||||
|
||||
End if
|
||||
|
||||
End Sub
|
||||
@@ -0,0 +1,230 @@
|
||||
' SwitchExportWinLineDoc_TableContent
|
||||
' ----------------------------------------------------------------------------
|
||||
' Diese Subroutine läd Daten beim Zeilenwechel im Grid und zeigt diese ggf. an.
|
||||
' Parameter 1 (LEVEL) = Das aktuelle Showlevel übergeben.
|
||||
' Parameter 2 (GRID) = Falls mehrere Grids auf einem Level vorkommen, kann über diesen Parameter nochmals unterscheiden werden.
|
||||
' Parameter 3 (UPDATE) = Falls vor dem Wechsel eine Prüfung auf geänderte Daten durchgeführt werden soll.
|
||||
'
|
||||
' ----------------------------------------------------------------------------
|
||||
' Copyright (c) 2021 by Digital Data GmbH
|
||||
'
|
||||
' Digital Data GmbH • Ludwig-Rinn-Strasse 16 • D-35452 Heuchelheim
|
||||
' Tel.: 0641/202360 • E-Mail: info-flow@digitaldata.works
|
||||
' ----------------------------------------------------------------------------
|
||||
' Creation Date / Author: 15.07.2021 / MK
|
||||
' Version Date / Editor: 15.07.2021 / MK
|
||||
' Version Number: 1.0.0.0
|
||||
|
||||
Sub SwitchExportWinLineDoc_TableContent(LEVEL,GRID,UPDATE)
|
||||
|
||||
'Set global var to prevent focus change -> "rumflackern"
|
||||
PREVENT_FOCUS_CHANGE = True
|
||||
|
||||
If (LEVEL = 1) or (LEVEL = "1") Then
|
||||
|
||||
If (GRID = LEVEL1_GRID_ID) Then
|
||||
|
||||
'Check if there are unsaved changes before switch line
|
||||
If (LEVEL1_GRID_CURRENT_ROW > 0) and ((LEVEL1_GRID_CURRENT_GUID > 0) and (LEVEL1_GRID_CURRENT_GUID <> -1)) and (UPDATE = true) Then
|
||||
|
||||
SaveExportWinLineDoc_Record CURRENT_LEVEL,LEVEL1_GRID_CURRENT_GUID,False
|
||||
|
||||
End If
|
||||
|
||||
LEVEL1_GRID.GetCurrentCell CURRENT_ROW, CURRENT_COLUMN
|
||||
GRIDSelectedLines = LEVEL1_GRID.SelectedLines
|
||||
|
||||
If isarray (GRIDSelectedLines) Then
|
||||
|
||||
If Ubound(GRIDSelectedLines) = 0 Then
|
||||
|
||||
LEVEL1_GRID_CURRENT_ROW = GRIDSelectedLines(0)
|
||||
LEVEL1_GRID_CURRENT_GUID = LEVEL1_GRID.GetCellValue(CURRENT_ROW,LEVEL1_GRID_COLUMN_GUID)
|
||||
LEVEL1_GRID_CURRENT_AKTIV = LEVEL1_GRID.GetCellValue(CURRENT_ROW,LEVEL1_GRID_COLUMN_AKTIV)
|
||||
LEVEL1_GRID_CURRENT_Beschreibung = LEVEL1_GRID.GetCellValue(CURRENT_ROW,LEVEL1_GRID_COLUMN_BESCHREIBUNG)
|
||||
LEVEL1_GRID_CURRENT_Mandant = LEVEL1_GRID.GetCellValue(CURRENT_ROW,LEVEL1_GRID_COLUMN_MANDANT)
|
||||
|
||||
If (DEBUG_ON = True) Or (DebugMode = "Enabled") Then
|
||||
msgbox "CURRENT_ROW: " & LEVEL1_GRID_CURRENT_ROW & vbCrlf & _
|
||||
"CURRENT_GUID: " & LEVEL1_GRID_CURRENT_GUID & vbCrlf & _
|
||||
"CURRENT_AKTIV: " & LEVEL1_GRID_CURRENT_AKTIV & vbCrlf & _
|
||||
"CURRENT_Beschreibung: " & LEVEL1_GRID_CURRENT_Beschreibung & vbCrlf & _
|
||||
"CURRENT_Mandant: " & LEVEL1_GRID_CURRENT_Mandant & vbCrlf & _
|
||||
"",vbOkayonly+vbInformation, DEBUG_TITLE & "SwitchExportWinLineDoc_TableContent"
|
||||
End If
|
||||
|
||||
If (LEVEL1_GRID_CURRENT_GUID > 0) Then
|
||||
|
||||
'For the first call the value allocation (.contents) must run through all fields
|
||||
'Otherwise every "Must-Field" must be clicked manually!
|
||||
'This is corresponding with the "bResult.Value" in the OnCheckUserfield Event
|
||||
LEVEL1_GRID_CALLCOUNT = LEVEL1_GRID_CALLCOUNT + 1
|
||||
|
||||
'Set static fields to activ
|
||||
EnableExportWinLineDoc_InputControls CURRENT_LEVEL,"static"
|
||||
|
||||
'get data for selected line
|
||||
GetExportWinLineDoc_Record CURRENT_LEVEL,LEVEL1_GRID_ID,CURRENT_GUID
|
||||
|
||||
'set data to the read only fields
|
||||
SetExportWinLineDoc_ReadOnlyControls CURRENT_LEVEL
|
||||
|
||||
'set data to the writable fields
|
||||
SetExportWinLineDoc_InputControls CURRENT_LEVEL,"static"
|
||||
|
||||
'Enable / Disable correponding Toolbar Buttons
|
||||
DisableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"dynamic"
|
||||
EnableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"dynamic"
|
||||
|
||||
End If
|
||||
|
||||
'For the first call set focus once to the "Must-Fields"
|
||||
IF ((LEVEL1_GRID_CURRENT_ROW > 0) and (LEVEL1_GRID_CURRENT_GUID > 0) and (LEVEL1_GRID_CALLCOUNT < 2)) Then
|
||||
|
||||
SetExportWinLineDoc_FocusToRequiredFields CURRENT_LEVEL
|
||||
|
||||
End if
|
||||
|
||||
Else
|
||||
|
||||
'Important in this case, to set these vars to 0 at first
|
||||
LEVEL1_GRID_CURRENT_ROW = 0
|
||||
LEVEL1_GRID_CURRENT_GUID = 0
|
||||
LEVEL1_GRID_CURRENT_AKTIV = 0
|
||||
LEVEL1_GRID_CURRENT_Beschreibung = 0
|
||||
LEVEL1_GRID_CURRENT_Mandant = 0
|
||||
|
||||
'If no valid line was selected, clear and disable input area
|
||||
EnableExportWinLineDoc_InputControls CURRENT_LEVEL,"static"
|
||||
SetExportWinLineDoc_InputControls CURRENT_LEVEL,"clear"
|
||||
DisableExportWinLineDoc_InputControls CURRENT_LEVEL,"static"
|
||||
|
||||
SetExportWinLineDoc_ReadOnlyControls CURRENT_LEVEL
|
||||
|
||||
'Disable correponding Toolbar Buttons
|
||||
DisableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"dynamic"
|
||||
EnableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"dynamic"
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
'--------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
ElseIf (LEVEL = 2) or (LEVEL = "2") Then
|
||||
|
||||
If (GRID = LEVEL2_GRID_ID) Then
|
||||
|
||||
'Check if there are unsaved changes before switch line
|
||||
If (LEVEL2_GRID_CURRENT_ROW > 0) and ((LEVEL2_GRID_CURRENT_GUID > 0) and (LEVEL2_GRID_CURRENT_GUID <> -1)) and (UPDATE = true) Then
|
||||
|
||||
SaveExportWinLineDoc_Record CURRENT_LEVEL,LEVEL2_GRID_CURRENT_GUID,False
|
||||
|
||||
End If
|
||||
|
||||
LEVEL2_GRID.GetCurrentCell CURRENT_ROW, CURRENT_COLUMN
|
||||
GRIDSelectedLines = LEVEL2_GRID.SelectedLines
|
||||
|
||||
If isarray (GRIDSelectedLines) Then
|
||||
|
||||
If Ubound(GRIDSelectedLines) = 0 Then
|
||||
|
||||
LEVEL2_GRID_CURRENT_ROW = GRIDSelectedLines(0)
|
||||
LEVEL2_GRID_CURRENT_GUID = LEVEL2_GRID.GetCellValue(CURRENT_ROW,LEVEL2_GRID_COLUMN_GUID)
|
||||
LEVEL2_GRID_CURRENT_AKTIV = LEVEL2_GRID.GetCellValue(CURRENT_ROW,LEVEL2_GRID_COLUMN_AKTIV)
|
||||
LEVEL2_GRID_CURRENT_Beschreibung = LEVEL2_GRID.GetCellValue(CURRENT_ROW,LEVEL2_GRID_COLUMN_BESCHREIBUNG)
|
||||
LEVEL2_GRID_CURRENT_Mandant = LEVEL2_GRID.GetCellValue(CURRENT_ROW,LEVEL2_GRID_COLUMN_MANDANT)
|
||||
|
||||
If (DEBUG_ON = True) Or (DebugMode = "Enabled") Then
|
||||
msgbox "CURRENT_ROW: " & LEVEL2_GRID_CURRENT_ROW & vbCrlf & _
|
||||
"CURRENT_GUID: " & LEVEL2_GRID_CURRENT_GUID & vbCrlf & _
|
||||
"CURRENT_AKTIV: " & LEVEL2_GRID_CURRENT_AKTIV & vbCrlf & _
|
||||
"CURRENT_Beschreibung: " & LEVEL2_GRID_CURRENT_Beschreibung & vbCrlf & _
|
||||
"CURRENT_Mandant: " & LEVEL2_GRID_CURRENT_Mandant & vbCrlf & _
|
||||
"",vbOkayonly+vbInformation, DEBUG_TITLE & "SwitchExportWinLineDoc_TableContent"
|
||||
End If
|
||||
|
||||
If (LEVEL2_GRID_CURRENT_GUID > 0) Then
|
||||
|
||||
'For the first call the value allocation (.contents) must run through all fields
|
||||
'Otherwise every "Must-Field" must be clicked manually!
|
||||
'This is corresponding with the "bResult.Value" in the OnCheckUserfield Event
|
||||
LEVEL2_GRID_CALLCOUNT = LEVEL2_GRID_CALLCOUNT + 1
|
||||
|
||||
'Set static fields to activ
|
||||
EnableExportWinLineDoc_InputControls CURRENT_LEVEL,"static"
|
||||
|
||||
'get data for selected line
|
||||
GetExportWinLineDoc_Record CURRENT_LEVEL,LEVEL2_GRID_ID,CURRENT_GUID
|
||||
|
||||
'set data to the read only fields
|
||||
SetExportWinLineDoc_ReadOnlyControls CURRENT_LEVEL
|
||||
|
||||
'set data to the writable fields
|
||||
SetExportWinLineDoc_InputControls CURRENT_LEVEL,"dynamic"
|
||||
|
||||
'Enable / Disable correponding Toolbar Buttons
|
||||
DisableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"dynamic"
|
||||
EnableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"dynamic"
|
||||
|
||||
'SPECIAL: set data type fileds depending on selcted type on/off
|
||||
DisableExportWinLineDoc_InputControls CURRENT_LEVEL,"dynamic"
|
||||
|
||||
'Check for duplicate on changing data, or new data, or changing someting else and pressing the save button
|
||||
SQLQuery_ConfigCount = SQLQuery_ConfigCount_Template
|
||||
SQLQuery_ConfigCount = Replace(SQLQuery_ConfigCount,"%LEVEL2_TXT_Platzhalter_Value%",LEVEL2_TXT_Platzhalter_DBValue)
|
||||
|
||||
Set SQLResult_ConfigCount = Conn.Select(SQLQuery_ConfigCount)
|
||||
IF ((SQLResult_ConfigCount.Rowcount > 1) and (LEVEL2_GRID_CALLCOUNT > 2)) Then
|
||||
Msgbox "Achtung: Der Platzerhalter " & LEVEL2_TXT_Platzhalter_DBValue & ", " & vbCrlf & _
|
||||
"wird bereits (" & SQLResult_ConfigCount.Rowcount & "x) verwendet!" & vbCrlf & vbCrlf & _
|
||||
"Bitte ändern Sie Ihre Eingabe, " & vbCrlf & _
|
||||
"ansonsten wird es zu Fehlern bei der Dateiablage kommen!" & vbCrlf & vbCrlf & _
|
||||
"Muster: %PLATZHALTER%" & vbCrlf & _
|
||||
"",vbInformation+vbOKOnly,DEFAULT_TITLE & " - Zeilenwechsel"
|
||||
|
||||
MacroCommands.MSetFieldFocus MAIN_WINDOW_ID,LEVEL2_TXT_Platzhalter_ID
|
||||
End if
|
||||
|
||||
End If
|
||||
|
||||
'For the first call set focus once to the "Must-Fields"
|
||||
IF ((LEVEL2_GRID_CURRENT_ROW > 0) and (LEVEL2_GRID_CURRENT_GUID > 0) and (LEVEL2_GRID_CALLCOUNT < 2)) Then
|
||||
|
||||
SetExportWinLineDoc_FocusToRequiredFields CURRENT_LEVEL
|
||||
|
||||
End if
|
||||
|
||||
Else
|
||||
|
||||
'Important in this case, to set these vars to 0 at first
|
||||
LEVEL2_GRID_CURRENT_ROW = 0
|
||||
LEVEL2_GRID_CURRENT_GUID = 0
|
||||
LEVEL2_GRID_CURRENT_AKTIV = 0
|
||||
LEVEL2_GRID_CURRENT_Beschreibung = 0
|
||||
LEVEL2_GRID_CURRENT_Mandant = 0
|
||||
|
||||
'If no valid line was selected, clear and disable input area
|
||||
EnableExportWinLineDoc_InputControls CURRENT_LEVEL,"static"
|
||||
SetExportWinLineDoc_InputControls CURRENT_LEVEL,"clear"
|
||||
DisableExportWinLineDoc_InputControls CURRENT_LEVEL,"static"
|
||||
|
||||
SetExportWinLineDoc_ReadOnlyControls CURRENT_LEVEL
|
||||
|
||||
'Disable correponding Toolbar Buttons
|
||||
DisableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"dynamic"
|
||||
EnableExportWinLineDoc_ButtonControls CURRENT_LEVEL,"dynamic"
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
End if
|
||||
|
||||
PREVENT_FOCUS_CHANGE = False
|
||||
|
||||
End Sub
|
||||
Reference in New Issue
Block a user