This commit is contained in:
SchreiberM
2016-08-30 15:27:13 +02:00
6 changed files with 86 additions and 10 deletions

View File

@@ -0,0 +1,19 @@
Imports System.ComponentModel
Public Class ClassAsyncSQL
Private sql As String
Public WithEvents bw As BackgroundWorker
Public dt As DataTable
Public Sub New(sqlCommand As String)
Me.bw = New BackgroundWorker()
bw.WorkerReportsProgress = False
bw.WorkerSupportsCancellation = False
Me.sql = sqlCommand
End Sub
Private Sub bw_DoWork(ByVal sender As Object, ByVal e As DoWorkEventArgs) Handles bw.DoWork
Me.dt = ClassDatabase.Return_Datatable(Me.sql, "LoadEntityData - Get DTEntity")
End Sub
End Class

View File

@@ -254,6 +254,7 @@
<Compile Include="ClassFolderWatcher.vb" /> <Compile Include="ClassFolderWatcher.vb" />
<Compile Include="ClassJumpRecord.vb" /> <Compile Include="ClassJumpRecord.vb" />
<Compile Include="ClassLicence.vb" /> <Compile Include="ClassLicence.vb" />
<Compile Include="ClassAsyncSQL.vb" />
<Compile Include="ClassNodes.vb" /> <Compile Include="ClassNodes.vb" />
<Compile Include="ClassRecordState.vb" /> <Compile Include="ClassRecordState.vb" />
<Compile Include="ClassRecordView.vb" /> <Compile Include="ClassRecordView.vb" />

View File

@@ -148,6 +148,8 @@ Partial Class frmConstructor_Main
Me.tsslblStatus = New System.Windows.Forms.ToolStripStatusLabel() Me.tsslblStatus = New System.Windows.Forms.ToolStripStatusLabel()
Me.tsslblRecord = New System.Windows.Forms.ToolStripStatusLabel() Me.tsslblRecord = New System.Windows.Forms.ToolStripStatusLabel()
Me.tsslblWorkflowstate = New System.Windows.Forms.ToolStripStatusLabel() Me.tsslblWorkflowstate = New System.Windows.Forms.ToolStripStatusLabel()
Me.labelLoadEntity = New System.Windows.Forms.ToolStripStatusLabel()
Me.progressLoadEntity = New System.Windows.Forms.ToolStripProgressBar()
Me.DD_ECMAdmin = New DD_Record_Organiser.DD_ECMAdmin() Me.DD_ECMAdmin = New DD_Record_Organiser.DD_ECMAdmin()
Me.ImageCollection1 = New DevExpress.Utils.ImageCollection(Me.components) Me.ImageCollection1 = New DevExpress.Utils.ImageCollection(Me.components)
Me.ttToolTip = New System.Windows.Forms.ToolTip(Me.components) Me.ttToolTip = New System.Windows.Forms.ToolTip(Me.components)
@@ -1003,7 +1005,7 @@ Partial Class frmConstructor_Main
' '
'StatusStrip_Main 'StatusStrip_Main
' '
Me.StatusStrip_Main.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.tsslblStatus, Me.tsslblRecord, Me.tsslblWorkflowstate}) Me.StatusStrip_Main.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.tsslblStatus, Me.tsslblRecord, Me.tsslblWorkflowstate, Me.labelLoadEntity, Me.progressLoadEntity})
resources.ApplyResources(Me.StatusStrip_Main, "StatusStrip_Main") resources.ApplyResources(Me.StatusStrip_Main, "StatusStrip_Main")
Me.StatusStrip_Main.Name = "StatusStrip_Main" Me.StatusStrip_Main.Name = "StatusStrip_Main"
' '
@@ -1030,6 +1032,17 @@ Partial Class frmConstructor_Main
Me.tsslblWorkflowstate.Name = "tsslblWorkflowstate" Me.tsslblWorkflowstate.Name = "tsslblWorkflowstate"
resources.ApplyResources(Me.tsslblWorkflowstate, "tsslblWorkflowstate") resources.ApplyResources(Me.tsslblWorkflowstate, "tsslblWorkflowstate")
' '
'labelLoadEntity
'
Me.labelLoadEntity.Name = "labelLoadEntity"
resources.ApplyResources(Me.labelLoadEntity, "labelLoadEntity")
'
'progressLoadEntity
'
Me.progressLoadEntity.Name = "progressLoadEntity"
resources.ApplyResources(Me.progressLoadEntity, "progressLoadEntity")
Me.progressLoadEntity.Style = System.Windows.Forms.ProgressBarStyle.Marquee
'
'DD_ECMAdmin 'DD_ECMAdmin
' '
Me.DD_ECMAdmin.DataSetName = "DD_ECMAdmin" Me.DD_ECMAdmin.DataSetName = "DD_ECMAdmin"
@@ -1304,4 +1317,6 @@ Partial Class frmConstructor_Main
Friend WithEvents TSMIDisplayname As System.Windows.Forms.ToolStripMenuItem Friend WithEvents TSMIDisplayname As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents tstbDisplayname As System.Windows.Forms.ToolStripTextBox Friend WithEvents tstbDisplayname As System.Windows.Forms.ToolStripTextBox
Friend WithEvents tsmiRights As System.Windows.Forms.ToolStripMenuItem Friend WithEvents tsmiRights As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents progressLoadEntity As System.Windows.Forms.ToolStripProgressBar
Friend WithEvents labelLoadEntity As System.Windows.Forms.ToolStripStatusLabel
End Class End Class

View File

@@ -325,7 +325,7 @@
<value>0, 0</value> <value>0, 0</value>
</data> </data>
<data name="GridControlMain.Size" type="System.Drawing.Size, System.Drawing"> <data name="GridControlMain.Size" type="System.Drawing.Size, System.Drawing">
<value>1067, 237</value> <value>1074, 237</value>
</data> </data>
<data name="GridControlMain.TabIndex" type="System.Int32, mscorlib"> <data name="GridControlMain.TabIndex" type="System.Int32, mscorlib">
<value>0</value> <value>0</value>
@@ -394,7 +394,7 @@
<value>0, 0</value> <value>0, 0</value>
</data> </data>
<data name="pnlDetails.Size" type="System.Drawing.Size, System.Drawing"> <data name="pnlDetails.Size" type="System.Drawing.Size, System.Drawing">
<value>1360, 343</value> <value>1356, 347</value>
</data> </data>
<data name="pnlDetails.TabIndex" type="System.Int32, mscorlib"> <data name="pnlDetails.TabIndex" type="System.Int32, mscorlib">
<value>0</value> <value>0</value>
@@ -412,7 +412,7 @@
<value>0</value> <value>0</value>
</data> </data>
<data name="TabDetails.Size" type="System.Drawing.Size, System.Drawing"> <data name="TabDetails.Size" type="System.Drawing.Size, System.Drawing">
<value>1360, 343</value> <value>1356, 347</value>
</data> </data>
<data name="TabDetails.Text" xml:space="preserve"> <data name="TabDetails.Text" xml:space="preserve">
<value>Detailansicht</value> <value>Detailansicht</value>
@@ -430,7 +430,7 @@
<value>0</value> <value>0</value>
</data> </data>
<data name="TCDetails.Size" type="System.Drawing.Size, System.Drawing"> <data name="TCDetails.Size" type="System.Drawing.Size, System.Drawing">
<value>1362, 371</value> <value>1362, 378</value>
</data> </data>
<data name="TCDetails.TabIndex" type="System.Int32, mscorlib"> <data name="TCDetails.TabIndex" type="System.Int32, mscorlib">
<value>1</value> <value>1</value>
@@ -1682,6 +1682,15 @@
<data name="tsslblWorkflowstate.Visible" type="System.Boolean, mscorlib"> <data name="tsslblWorkflowstate.Visible" type="System.Boolean, mscorlib">
<value>False</value> <value>False</value>
</data> </data>
<data name="labelLoadEntity.Size" type="System.Drawing.Size, System.Drawing">
<value>83, 19</value>
</data>
<data name="labelLoadEntity.Text" xml:space="preserve">
<value>Loading Data..</value>
</data>
<data name="progressLoadEntity.Size" type="System.Drawing.Size, System.Drawing">
<value>100, 18</value>
</data>
<data name="StatusStrip_Main.Location" type="System.Drawing.Point, System.Drawing"> <data name="StatusStrip_Main.Location" type="System.Drawing.Point, System.Drawing">
<value>0, 685</value> <value>0, 685</value>
</data> </data>
@@ -1766,7 +1775,7 @@
<value>True</value> <value>True</value>
</metadata> </metadata>
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>194</value> <value>88</value>
</metadata> </metadata>
<data name="$this.AutoScaleDimensions" type="System.Drawing.SizeF, System.Drawing"> <data name="$this.AutoScaleDimensions" type="System.Drawing.SizeF, System.Drawing">
<value>6, 13</value> <value>6, 13</value>
@@ -2745,6 +2754,18 @@
<data name="&gt;&gt;tsslblWorkflowstate.Type" xml:space="preserve"> <data name="&gt;&gt;tsslblWorkflowstate.Type" xml:space="preserve">
<value>System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> <value>System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data> </data>
<data name="&gt;&gt;labelLoadEntity.Name" xml:space="preserve">
<value>labelLoadEntity</value>
</data>
<data name="&gt;&gt;labelLoadEntity.Type" xml:space="preserve">
<value>System.Windows.Forms.ToolStripStatusLabel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;progressLoadEntity.Name" xml:space="preserve">
<value>progressLoadEntity</value>
</data>
<data name="&gt;&gt;progressLoadEntity.Type" xml:space="preserve">
<value>System.Windows.Forms.ToolStripProgressBar, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;DD_ECMAdmin.Name" xml:space="preserve"> <data name="&gt;&gt;DD_ECMAdmin.Name" xml:space="preserve">
<value>DD_ECMAdmin</value> <value>DD_ECMAdmin</value>
</data> </data>

View File

@@ -1222,6 +1222,8 @@ Public Class frmConstructor_Main
foundRowsLevel0 = DT_TREEVIEW_PER_CONTROLS.Select(expression) foundRowsLevel0 = DT_TREEVIEW_PER_CONTROLS.Select(expression)
Dim i As Integer Dim i As Integer
Dim NODE_CONFIG_ID Dim NODE_CONFIG_ID
Dim LEVEL0_NODE As TreeNode
' For each row create a Node ' For each row create a Node
For i = 0 To foundRowsLevel0.GetUpperBound(0) For i = 0 To foundRowsLevel0.GetUpperBound(0)
Dim ID = foundRowsLevel0(i)("GUID") Dim ID = foundRowsLevel0(i)("GUID")
@@ -1231,7 +1233,7 @@ Public Class frmConstructor_Main
Dim Type_node = foundRowsLevel0(i)("TYPE_NODE") Dim Type_node = foundRowsLevel0(i)("TYPE_NODE")
Dim RECORD_ID = foundRowsLevel0(i)("RECORD_ID") Dim RECORD_ID = foundRowsLevel0(i)("RECORD_ID")
NODE_CONFIG_ID = foundRowsLevel0(i)("NODE_CONFIG_ID") NODE_CONFIG_ID = foundRowsLevel0(i)("NODE_CONFIG_ID")
Dim LEVEL0_NODE As TreeNode
LEVEL0_NODE = New TreeNode(nodetext) LEVEL0_NODE = New TreeNode(nodetext)
If Not IsDBNull(RECORD_ID) Then If Not IsDBNull(RECORD_ID) Then
LEVEL0_NODE.Tag = LevelEntity & " - CONTROL-ID" & controlID.ToString & "#" & ID & "#RECORD-ID" & RECORD_ID.ToString LEVEL0_NODE.Tag = LevelEntity & " - CONTROL-ID" & controlID.ToString & "#" & ID & "#RECORD-ID" & RECORD_ID.ToString
@@ -1248,7 +1250,7 @@ Public Class frmConstructor_Main
Next Next
LEVEL0_NODE.ImageIndex = index LEVEL0_NODE.ImageIndex = index
LEVEL0_NODE.SelectedImageIndex = index LEVEL0_NODE.SelectedImageIndex = index
TreeViewMain.Nodes.Add(LEVEL0_NODE)
'### LEVEL 1 laden ####### '### LEVEL 1 laden #######
Dim expressionLevel1 As String Dim expressionLevel1 As String
expressionLevel1 = "PARENT_GUID = " & ID 'TYPE_NODE = 1 AND Einschränkung auf Type 2 und Parent_Guid expressionLevel1 = "PARENT_GUID = " & ID 'TYPE_NODE = 1 AND Einschränkung auf Type 2 und Parent_Guid
@@ -1532,6 +1534,8 @@ Public Class frmConstructor_Main
Next 'Level 1 Ende Next 'Level 1 Ende
Next Next
TreeViewMain.Nodes.Add(LEVEL0_NODE)
Else Else
MsgBox("Check the Control Navigation Option or inform Digital Data!", MsgBoxStyle.Critical) MsgBox("Check the Control Navigation Option or inform Digital Data!", MsgBoxStyle.Critical)
@@ -1741,7 +1745,7 @@ Public Class frmConstructor_Main
FAU_AD_USER_PW = PWplainText FAU_AD_USER_PW = PWplainText
Next Next
End If End If
Dim elapsed As Double Dim elapsed As Double
elapsed = sw.Elapsed.TotalSeconds elapsed = sw.Elapsed.TotalSeconds
@@ -2726,7 +2730,20 @@ Public Class frmConstructor_Main
TabDetails.PageVisible = True TabDetails.PageVisible = True
GridControlMain.Visible = True GridControlMain.Visible = True
Dim DTEntity As DataTable = ClassDatabase.Return_Datatable(_ENTITYSQL, "LoadEntityData - Get DTEntity") progressLoadEntity.Visible = True
labelLoadEntity.Visible = True
Dim async As New ClassAsyncSQL(_ENTITYSQL)
async.bw.RunWorkerAsync()
While async.bw.IsBusy
Application.DoEvents()
End While
progressLoadEntity.Visible = False
labelLoadEntity.Visible = False
Dim DTEntity As DataTable = async.dt
'Dim DTEntity As DataTable = ClassDatabase.Return_Datatable(_ENTITYSQL, "LoadEntityData - Get DTEntity")
DTEntity.TableName = "VWTEMP_PMO_FORM" & ENTITY_ID DTEntity.TableName = "VWTEMP_PMO_FORM" & ENTITY_ID
If IsNothing(DTEntity) Then If IsNothing(DTEntity) Then
MsgBox("Unexpected Error in getting Entity-Data - Check Logfile", MsgBoxStyle.Critical) MsgBox("Unexpected Error in getting Entity-Data - Check Logfile", MsgBoxStyle.Critical)

View File

@@ -640,6 +640,9 @@
noerror = ClassDatabase.Execute_non_Query_withConn(sql, 1) noerror = ClassDatabase.Execute_non_Query_withConn(sql, 1)
sql = "EXECUTE PRPMO_CREATE_TEMP_VIEWS" sql = "EXECUTE PRPMO_CREATE_TEMP_VIEWS"
noerror = ClassDatabase.Execute_non_Query_withConn(sql, 1) noerror = ClassDatabase.Execute_non_Query_withConn(sql, 1)
If noerror = False Then
MsgBox("Error while Rebuilding Views! See Log for more information", MsgBoxStyle.Critical)
End If
Return noerror Return noerror
Catch ex As Exception Catch ex As Exception
MsgBox("Error in btnexecute_CreateViewSql:" & vbNewLine & ex.Message, MsgBoxStyle.Critical) MsgBox("Error in btnexecute_CreateViewSql:" & vbNewLine & ex.Message, MsgBoxStyle.Critical)