add lookupgrid2, try to fuck around with that dataset of DOOM
This commit is contained in:
parent
2fcec8d2b6
commit
041916262f
Binary file not shown.
@ -161,8 +161,8 @@ Public Class ClassControlCreator
|
||||
Return control
|
||||
End Function
|
||||
|
||||
Friend Shared Function CreateNewLookupControl(location As Point) As LookupControl
|
||||
Dim control As New LookupControl With {
|
||||
Friend Shared Function CreateNewLookupControl(location As Point) As LookupControl2
|
||||
Dim control As New LookupControl2 With {
|
||||
.Name = $"{PREFIX_DATAGRIDVIEW}_{clsTools.ShortGuid}",
|
||||
.Size = New Size(DEFAULT_WIDTH, DEFAULT_HEIGHT),
|
||||
.Cursor = Cursors.Hand,
|
||||
@ -305,8 +305,9 @@ Public Class ClassControlCreator
|
||||
Return control
|
||||
End Function
|
||||
|
||||
Public Shared Function CreateExistingLookupControl(row As DataRow, designMode As Boolean) As LookupControl
|
||||
Dim control As LookupControl = CreateBaseControl(New LookupControl(), row, designMode)
|
||||
Public Shared Function CreateExistingLookupControl(row As DataRow, designMode As Boolean) As LookupControl2
|
||||
Dim control As LookupControl2 = CreateBaseControl(New LookupControl2(), row, designMode)
|
||||
control.Width = row.Item("WIDTH")
|
||||
|
||||
If designMode Then
|
||||
control.Cursor = Cursors.Hand
|
||||
|
||||
@ -4,10 +4,14 @@
|
||||
Public Const INDEX_TYPE_FLOAT = 3
|
||||
Public Const INDEX_TYPE_BOOLEAN = 4
|
||||
Public Const INDEX_TYPE_DATE = 5
|
||||
Public Const INDEX_TYPE_VECTOR_INTEGER = 4107
|
||||
Public Const INDEX_TYPE_VECTOR_INTEGER_64 = 4107
|
||||
Public Const INDEX_TYPE_VECTOR_INTEGER = 4098
|
||||
Public Const INDEX_TYPE_VECTOR_STRING = 4097
|
||||
Public Const INDEX_TYPE_VECTOR_BOOLEAN = 4100
|
||||
Public Const INDEX_TYPE_VECTOR_DATE = 4101
|
||||
Public Const INDEX_TYPE_VECTOR_CURRENCY = 4104
|
||||
Public Const INDEX_TYPE_VECTOR_FLOAT = 4099
|
||||
Public Const INDEX_TYPE_VECTOR_DATETIME = 4103
|
||||
|
||||
Public Const PREFIX_VECTOR = "[%VKT"
|
||||
|
||||
@ -20,7 +24,7 @@
|
||||
|
||||
If type = INDEX_TYPE_STRING Or type = INDEX_TYPE_VECTOR_STRING Then
|
||||
value = props.StringValue
|
||||
ElseIf type = INDEX_TYPE_INTEGER Or type = INDEX_TYPE_VECTOR_INTEGER Then
|
||||
ElseIf type = INDEX_TYPE_INTEGER Or type = INDEX_TYPE_VECTOR_INTEGER_64 Then
|
||||
value = props.IntegerValue.ToString
|
||||
ElseIf type = INDEX_TYPE_FLOAT Then
|
||||
value = props.FloatValue.ToString
|
||||
@ -63,7 +67,7 @@
|
||||
value = NotNull(value, "")
|
||||
|
||||
props.StringValue = value
|
||||
ElseIf type = INDEX_TYPE_INTEGER Or type = INDEX_TYPE_VECTOR_INTEGER Then
|
||||
ElseIf type = INDEX_TYPE_INTEGER Or type = INDEX_TYPE_VECTOR_INTEGER_64 Then
|
||||
value = NotNull(Of Integer)(value, 0)
|
||||
|
||||
If value = String.Empty Then
|
||||
@ -97,7 +101,7 @@
|
||||
End Function
|
||||
|
||||
Public Shared Function IsVectorIndex(type As Integer) As Boolean
|
||||
If type = INDEX_TYPE_VECTOR_BOOLEAN Or type = INDEX_TYPE_VECTOR_DATE Or type = INDEX_TYPE_VECTOR_INTEGER Or type = INDEX_TYPE_VECTOR_STRING Then
|
||||
If type = INDEX_TYPE_VECTOR_BOOLEAN Or type = INDEX_TYPE_VECTOR_DATE Or type = INDEX_TYPE_VECTOR_INTEGER_64 Or type = INDEX_TYPE_VECTOR_STRING Then
|
||||
Return True
|
||||
Else
|
||||
Return False
|
||||
|
||||
@ -58,13 +58,49 @@ Module ModuleFinalIndexProperties
|
||||
<[ReadOnly](True)>
|
||||
Public Property VectorIndex As Boolean
|
||||
|
||||
<Category("Index")>
|
||||
<PropertyAttributesProvider("VectorIndexBooleanProvider")>
|
||||
Public Property AllowAddNewValues As Boolean
|
||||
<Category("Index")>
|
||||
<PropertyAttributesProvider("VectorIndexBooleanProvider")>
|
||||
Public Property PreventDuplicates As Boolean
|
||||
|
||||
' Eigenschaften für die Liste der Indicies
|
||||
<Browsable(False)>
|
||||
Public Property Indicies As List(Of String)
|
||||
<Browsable(False)>
|
||||
Public Property IndiciesType As List(Of Integer)
|
||||
|
||||
Public Sub MaybeSetReadOnly(attrs As PropertyAttributes)
|
||||
Public Sub VectorIndexBooleanProvider(attrs As PropertyAttributes)
|
||||
MaybeSetReadOnlyIfNotVectorIndex(attrs)
|
||||
End Sub
|
||||
|
||||
Public Sub IndexTypeBooleanProvider(attrs As PropertyAttributes)
|
||||
MaybeSetBrowsable(attrs, {ClassFinalIndex.INDEX_TYPE_BOOLEAN, ClassFinalIndex.INDEX_TYPE_VECTOR_BOOLEAN})
|
||||
MaybeSetReadOnlyIfSQLHasNoValue(attrs)
|
||||
End Sub
|
||||
|
||||
Public Sub IndexTypeStringProvider(attrs As PropertyAttributes)
|
||||
MaybeSetBrowsable(attrs, {ClassFinalIndex.INDEX_TYPE_STRING, ClassFinalIndex.INDEX_TYPE_VECTOR_STRING})
|
||||
MaybeSetReadOnlyIfSQLHasNoValue(attrs)
|
||||
End Sub
|
||||
|
||||
Public Sub IndexTypeFloatProvider(attrs As PropertyAttributes)
|
||||
MaybeSetBrowsable(attrs, {ClassFinalIndex.INDEX_TYPE_FLOAT})
|
||||
MaybeSetReadOnlyIfSQLHasNoValue(attrs)
|
||||
End Sub
|
||||
|
||||
Public Sub IndexTypeIntegerProvider(attrs As PropertyAttributes)
|
||||
MaybeSetBrowsable(attrs, {ClassFinalIndex.INDEX_TYPE_INTEGER, ClassFinalIndex.INDEX_TYPE_VECTOR_INTEGER_64})
|
||||
MaybeSetReadOnlyIfSQLHasNoValue(attrs)
|
||||
End Sub
|
||||
|
||||
Public Sub IndexTypeDateProvider(attrs As PropertyAttributes)
|
||||
MaybeSetBrowsable(attrs, {ClassFinalIndex.INDEX_TYPE_DATE, ClassFinalIndex.INDEX_TYPE_VECTOR_DATE})
|
||||
MaybeSetReadOnlyIfSQLHasNoValue(attrs)
|
||||
End Sub
|
||||
|
||||
Public Sub MaybeSetReadOnlyIfSQLHasNoValue(attrs As PropertyAttributes)
|
||||
Dim hasSQLValue As Boolean = (SQLCommand.Value <> String.Empty)
|
||||
|
||||
If hasSQLValue Then
|
||||
@ -74,6 +110,35 @@ Module ModuleFinalIndexProperties
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Public Sub MaybeSetReadOnlyIfNotVectorIndex(attrs As PropertyAttributes)
|
||||
' Get index (position in array) for selected index (windream)
|
||||
Dim oIndex As Integer = Indicies.IndexOf(IndexName)
|
||||
If oIndex < 0 Then
|
||||
attrs.IsReadOnly = True
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
' get type of windream index
|
||||
Dim oType As Integer = IndiciesType.Item(oIndex)
|
||||
Dim oVectoryTypes = {
|
||||
ClassFinalIndex.INDEX_TYPE_VECTOR_DATE,
|
||||
ClassFinalIndex.INDEX_TYPE_VECTOR_BOOLEAN,
|
||||
ClassFinalIndex.INDEX_TYPE_VECTOR_INTEGER_64,
|
||||
ClassFinalIndex.INDEX_TYPE_VECTOR_INTEGER,
|
||||
ClassFinalIndex.INDEX_TYPE_VECTOR_STRING,
|
||||
ClassFinalIndex.INDEX_TYPE_VECTOR_CURRENCY,
|
||||
ClassFinalIndex.INDEX_TYPE_VECTOR_FLOAT,
|
||||
ClassFinalIndex.INDEX_TYPE_VECTOR_DATETIME
|
||||
}
|
||||
|
||||
' if type of index is not a vector, set attribute to read only
|
||||
If oVectoryTypes.Contains(oType) Then
|
||||
attrs.IsReadOnly = False
|
||||
Else
|
||||
attrs.IsReadOnly = True
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Public Sub MaybeSetBrowsable(attrs As PropertyAttributes, indexType As Integer())
|
||||
Dim i As Integer = Indicies.IndexOf(IndexName)
|
||||
|
||||
@ -92,29 +157,6 @@ Module ModuleFinalIndexProperties
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Public Sub IndexTypeBooleanProvider(attrs As PropertyAttributes)
|
||||
MaybeSetBrowsable(attrs, {ClassFinalIndex.INDEX_TYPE_BOOLEAN, ClassFinalIndex.INDEX_TYPE_VECTOR_BOOLEAN})
|
||||
MaybeSetReadOnly(attrs)
|
||||
End Sub
|
||||
|
||||
Public Sub IndexTypeStringProvider(attrs As PropertyAttributes)
|
||||
MaybeSetBrowsable(attrs, {ClassFinalIndex.INDEX_TYPE_STRING, ClassFinalIndex.INDEX_TYPE_VECTOR_STRING})
|
||||
MaybeSetReadOnly(attrs)
|
||||
End Sub
|
||||
|
||||
Public Sub IndexTypeFloatProvider(attrs As PropertyAttributes)
|
||||
MaybeSetBrowsable(attrs, {ClassFinalIndex.INDEX_TYPE_FLOAT})
|
||||
MaybeSetReadOnly(attrs)
|
||||
End Sub
|
||||
|
||||
Public Sub IndexTypeIntegerProvider(attrs As PropertyAttributes)
|
||||
MaybeSetBrowsable(attrs, {ClassFinalIndex.INDEX_TYPE_INTEGER, ClassFinalIndex.INDEX_TYPE_VECTOR_INTEGER})
|
||||
MaybeSetReadOnly(attrs)
|
||||
End Sub
|
||||
|
||||
Public Sub IndexTypeDateProvider(attrs As PropertyAttributes)
|
||||
MaybeSetBrowsable(attrs, {ClassFinalIndex.INDEX_TYPE_DATE, ClassFinalIndex.INDEX_TYPE_VECTOR_DATE})
|
||||
MaybeSetReadOnly(attrs)
|
||||
End Sub
|
||||
End Class
|
||||
End Module
|
||||
|
||||
33
app/DD_PM_WINDREAM/frmAdministration.Designer.vb
generated
33
app/DD_PM_WINDREAM/frmAdministration.Designer.vb
generated
@ -22,7 +22,6 @@ Partial Class frmAdministration
|
||||
'Das Bearbeiten mit dem Code-Editor ist nicht möglich.
|
||||
<System.Diagnostics.DebuggerStepThrough()>
|
||||
Private Sub InitializeComponent()
|
||||
Me.components = New System.ComponentModel.Container()
|
||||
Dim GUIDLabel As System.Windows.Forms.Label
|
||||
Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmAdministration))
|
||||
Dim NAMELabel As System.Windows.Forms.Label
|
||||
@ -52,7 +51,7 @@ Partial Class frmAdministration
|
||||
Dim DataGridViewCellStyle1 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
|
||||
Me.SplitContainer_Profilzuordnung2 = New System.Windows.Forms.SplitContainer()
|
||||
Me.gridAssignedUsers = New DevExpress.XtraGrid.GridControl()
|
||||
Me.TBPROFILE_USERBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.TBPROFILE_USERBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.DD_DMSLiteDataSet = New DD_PM_WINDREAM.DD_DMSLiteDataSet()
|
||||
Me.viewAssignedUsers = New DevExpress.XtraGrid.Views.Grid.GridView()
|
||||
Me.colPRENAME1 = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
@ -64,7 +63,7 @@ Partial Class frmAdministration
|
||||
Me.Panel1 = New System.Windows.Forms.Panel()
|
||||
Me.Label20 = New System.Windows.Forms.Label()
|
||||
Me.gridAvailableUsers = New DevExpress.XtraGrid.GridControl()
|
||||
Me.FNPM_GET_FREE_USER_FOR_PROFILEBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.FNPM_GET_FREE_USER_FOR_PROFILEBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.viewAvailableUsers = New DevExpress.XtraGrid.Views.Grid.GridView()
|
||||
Me.colPRENAME = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
Me.colNAME2 = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
@ -76,22 +75,22 @@ Partial Class frmAdministration
|
||||
Me.Label19 = New System.Windows.Forms.Label()
|
||||
Me.SplitContainer1 = New System.Windows.Forms.SplitContainer()
|
||||
Me.gridAssignedGroups = New DevExpress.XtraGrid.GridControl()
|
||||
Me.TBPROFILE_GROUPBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.TBPROFILE_GROUPBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.viewAssignedGroups = New DevExpress.XtraGrid.Views.Grid.GridView()
|
||||
Me.colNAME5 = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
Me.colCOMMENT1 = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
Me.Panel3 = New System.Windows.Forms.Panel()
|
||||
Me.Label22 = New System.Windows.Forms.Label()
|
||||
Me.gridAvailableGroups = New DevExpress.XtraGrid.GridControl()
|
||||
Me.TBDD_GROUPSBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.TBDD_GROUPSBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.viewAvailableGroups = New DevExpress.XtraGrid.Views.Grid.GridView()
|
||||
Me.colNAME4 = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
Me.colCOMMENT = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
Me.Panel4 = New System.Windows.Forms.Panel()
|
||||
Me.Label23 = New System.Windows.Forms.Label()
|
||||
Me.TBDD_USERBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.TBDD_USERBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.TableAdapterManager = New DD_PM_WINDREAM.DD_DMSLiteDataSetTableAdapters.TableAdapterManager()
|
||||
Me.TBPM_PROFILEBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.TBPM_PROFILEBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.TBPM_PROFILETableAdapter = New DD_PM_WINDREAM.DD_DMSLiteDataSetTableAdapters.TBPM_PROFILETableAdapter()
|
||||
Me.BindingNavigatorMoveFirstItem = New System.Windows.Forms.ToolStripButton()
|
||||
Me.BindingNavigatorMovePreviousItem = New System.Windows.Forms.ToolStripButton()
|
||||
@ -103,7 +102,7 @@ Partial Class frmAdministration
|
||||
Me.BindingNavigatorMoveLastItem = New System.Windows.Forms.ToolStripButton()
|
||||
Me.BindingNavigatorSeparator2 = New System.Windows.Forms.ToolStripSeparator()
|
||||
Me.VWPM_PROFILE_USERBindingNavigatorSaveItem = New System.Windows.Forms.ToolStripButton()
|
||||
Me.TBPM_PROFILEBindingNavigator = New System.Windows.Forms.BindingNavigator(Me.components)
|
||||
Me.TBPM_PROFILEBindingNavigator = New System.Windows.Forms.BindingNavigator()
|
||||
Me.tstrpbtn_add = New System.Windows.Forms.ToolStripButton()
|
||||
Me.tstrlblSave = New System.Windows.Forms.ToolStripLabel()
|
||||
Me.btnRefreshProfiles = New System.Windows.Forms.ToolStripButton()
|
||||
@ -122,7 +121,7 @@ Partial Class frmAdministration
|
||||
Me.GroupBox2 = New System.Windows.Forms.GroupBox()
|
||||
Me.Label1 = New System.Windows.Forms.Label()
|
||||
Me.cmbType = New System.Windows.Forms.ComboBox()
|
||||
Me.TBPM_TYPEBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.TBPM_TYPEBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.GroupBox3 = New System.Windows.Forms.GroupBox()
|
||||
Me.MOVE2FOLDERTextBox = New System.Windows.Forms.TextBox()
|
||||
Me.btnmovetoFolderDialog = New System.Windows.Forms.Button()
|
||||
@ -158,7 +157,7 @@ Partial Class frmAdministration
|
||||
Me.TabPage11 = New System.Windows.Forms.TabPage()
|
||||
Me.Panel5 = New System.Windows.Forms.Panel()
|
||||
Me.gridFinalIndex = New DevExpress.XtraGrid.GridControl()
|
||||
Me.TBPM_PROFILE_FINAL_INDEXINGBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.TBPM_PROFILE_FINAL_INDEXINGBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.viewFinalIndex = New DevExpress.XtraGrid.Views.Grid.GridView()
|
||||
Me.colGUID = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
Me.colINDEXNAME = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
@ -169,7 +168,7 @@ Partial Class frmAdministration
|
||||
Me.colCHANGED_WHO = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
Me.colCHANGED_WHEN = New DevExpress.XtraGrid.Columns.GridColumn()
|
||||
Me.PropertyGrid1 = New System.Windows.Forms.PropertyGrid()
|
||||
Me.BindingNavigator1 = New System.Windows.Forms.BindingNavigator(Me.components)
|
||||
Me.BindingNavigator1 = New System.Windows.Forms.BindingNavigator()
|
||||
Me.BindingNavigatorAddNewItem = New System.Windows.Forms.ToolStripButton()
|
||||
Me.BindingNavigatorCountItem1 = New System.Windows.Forms.ToolStripLabel()
|
||||
Me.BindingNavigatorMoveFirstItem1 = New System.Windows.Forms.ToolStripButton()
|
||||
@ -206,7 +205,7 @@ Partial Class frmAdministration
|
||||
Me.btnUserManager = New System.Windows.Forms.Button()
|
||||
Me.Button2 = New System.Windows.Forms.Button()
|
||||
Me.VEKTOR_DELIMITERTextBox = New System.Windows.Forms.TextBox()
|
||||
Me.TBPM_KONFIGURATIONBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.TBPM_KONFIGURATIONBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.btnConnections = New System.Windows.Forms.Button()
|
||||
Me.btnopen_SQLAdmin = New System.Windows.Forms.Button()
|
||||
Me.EMAIL_ACTIVECheckBox = New System.Windows.Forms.CheckBox()
|
||||
@ -234,8 +233,8 @@ Partial Class frmAdministration
|
||||
Me.DataGridViewTextBoxColumn23 = New System.Windows.Forms.DataGridViewTextBoxColumn()
|
||||
Me.DataGridViewTextBoxColumn24 = New System.Windows.Forms.DataGridViewTextBoxColumn()
|
||||
Me.DataGridViewTextBoxColumn25 = New System.Windows.Forms.DataGridViewTextBoxColumn()
|
||||
Me.TBPM_ERROR_LOGBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.TBPM_ERROR_LOGBindingNavigator = New System.Windows.Forms.BindingNavigator(Me.components)
|
||||
Me.TBPM_ERROR_LOGBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.TBPM_ERROR_LOGBindingNavigator = New System.Windows.Forms.BindingNavigator()
|
||||
Me.BindingNavigatorCountItem3 = New System.Windows.Forms.ToolStripLabel()
|
||||
Me.BindingNavigatorDeleteItem1 = New System.Windows.Forms.ToolStripButton()
|
||||
Me.BindingNavigatorMoveFirstItem3 = New System.Windows.Forms.ToolStripButton()
|
||||
@ -246,8 +245,8 @@ Partial Class frmAdministration
|
||||
Me.BindingNavigatorMoveNextItem3 = New System.Windows.Forms.ToolStripButton()
|
||||
Me.BindingNavigatorMoveLastItem3 = New System.Windows.Forms.ToolStripButton()
|
||||
Me.BindingNavigatorSeparator11 = New System.Windows.Forms.ToolStripSeparator()
|
||||
Me.TBDD_CONNECTIONBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.TBPM_PROFILE_CONTROLSBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.TBDD_CONNECTIONBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.TBPM_PROFILE_CONTROLSBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.StatusStrip1 = New System.Windows.Forms.StatusStrip()
|
||||
Me.tstrpinfo = New System.Windows.Forms.ToolStripStatusLabel()
|
||||
Me.TBPROFILE_USERTableAdapter = New DD_PM_WINDREAM.DD_DMSLiteDataSetTableAdapters.TBPROFILE_USERTableAdapter()
|
||||
@ -257,7 +256,7 @@ Partial Class frmAdministration
|
||||
Me.TBPM_ERROR_LOGTableAdapter = New DD_PM_WINDREAM.DD_DMSLiteDataSetTableAdapters.TBPM_ERROR_LOGTableAdapter()
|
||||
Me.TBPM_PROFILE_FINAL_INDEXINGTableAdapter = New DD_PM_WINDREAM.DD_DMSLiteDataSetTableAdapters.TBPM_PROFILE_FINAL_INDEXINGTableAdapter()
|
||||
Me.TBPM_PROFILE_CONTROLSTableAdapter = New DD_PM_WINDREAM.DD_DMSLiteDataSetTableAdapters.TBPM_PROFILE_CONTROLSTableAdapter()
|
||||
Me.TBPM_PROFILE_FILESBindingSource = New System.Windows.Forms.BindingSource(Me.components)
|
||||
Me.TBPM_PROFILE_FILESBindingSource = New System.Windows.Forms.BindingSource()
|
||||
Me.TBPM_PROFILE_FILESTableAdapter = New DD_PM_WINDREAM.DD_DMSLiteDataSetTableAdapters.TBPM_PROFILE_FILESTableAdapter()
|
||||
Me.TBDD_CONNECTIONTableAdapter = New DD_PM_WINDREAM.DD_DMSLiteDataSetTableAdapters.TBDD_CONNECTIONTableAdapter()
|
||||
Me.TBDD_GROUPSTableAdapter = New DD_PM_WINDREAM.DD_DMSLiteDataSetTableAdapters.TBDD_GROUPSTableAdapter()
|
||||
|
||||
@ -565,7 +565,7 @@
|
||||
<value>58</value>
|
||||
</data>
|
||||
<data name="gridAssignedGroups.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>901, 267</value>
|
||||
<value>901, 264</value>
|
||||
</data>
|
||||
<data name="gridAssignedGroups.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>3</value>
|
||||
@ -688,7 +688,7 @@
|
||||
<value>58</value>
|
||||
</data>
|
||||
<data name="gridAvailableGroups.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>901, 234</value>
|
||||
<value>901, 233</value>
|
||||
</data>
|
||||
<data name="gridAvailableGroups.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>0</value>
|
||||
@ -775,10 +775,10 @@
|
||||
<value>1</value>
|
||||
</data>
|
||||
<data name="SplitContainer1.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>901, 555</value>
|
||||
<value>901, 551</value>
|
||||
</data>
|
||||
<data name="SplitContainer1.SplitterDistance" type="System.Int32, mscorlib">
|
||||
<value>292</value>
|
||||
<value>289</value>
|
||||
</data>
|
||||
<data name="SplitContainer1.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>1</value>
|
||||
@ -3434,7 +3434,7 @@ der Wertänderungen nutzen wollen:</value>
|
||||
<value>3, 3, 3, 3</value>
|
||||
</data>
|
||||
<data name="TabPage8.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>907, 561</value>
|
||||
<value>907, 557</value>
|
||||
</data>
|
||||
<data name="TabPage8.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>1</value>
|
||||
|
||||
@ -6,6 +6,7 @@ Imports DevExpress.XtraGrid
|
||||
Imports DevExpress.XtraGrid.Views.Grid
|
||||
|
||||
Public Class frmAdministration
|
||||
|
||||
'Private _windreamPM As ClassPMWindream
|
||||
Private email As New ClassEmail
|
||||
Public profile_guid As Integer = 0
|
||||
@ -956,6 +957,8 @@ LOGGER.Error(ex)
|
||||
Dim value As String = NotNull(focusedRow.Item("VALUE"), "")
|
||||
Dim active As Boolean = NotNull(focusedRow.Item("ACTIVE"), True)
|
||||
Dim description As String = NotNull(focusedRow.Item("DESCRIPTION"), "")
|
||||
Dim preventDuplicates As Boolean = NotNull(focusedRow.Item("PREVENT_DUPLICATES"), False)
|
||||
Dim allowNewValues As Boolean = NotNull(focusedRow.Item("ALLOW_NEW_VALUES"), False)
|
||||
|
||||
CURRENT_INDEX_ID = guid
|
||||
CURRENT_SQL_CON = connectionId
|
||||
@ -967,8 +970,8 @@ LOGGER.Error(ex)
|
||||
obj.ConnectionId = connectionId
|
||||
obj.Description = description
|
||||
obj.Active = active
|
||||
|
||||
|
||||
obj.AllowAddNewValues = allowNewValues
|
||||
obj.PreventDuplicates = preventDuplicates
|
||||
|
||||
' Wenn eine neue Zeile hinzugefügt wird, auf StringValue setzen
|
||||
If e.FocusedRowHandle <> GridControl.NewItemRowHandle Then
|
||||
@ -1050,6 +1053,8 @@ LOGGER.Error(ex)
|
||||
Dim addedWho As String = Environment.UserName
|
||||
Dim description As String = obj.Description
|
||||
Dim active As Integer = IIf(obj.Active, 1, 0)
|
||||
Dim preventDuplicates As Integer = IIf(obj.PreventDuplicates, 1, 0)
|
||||
Dim AllowAddNewValues As Integer = IIf(obj.AllowAddNewValues, 1, 0)
|
||||
|
||||
If indexName = String.Empty Then
|
||||
MsgBox("Das Feld IndexName muss ausgefüllt sein!", MsgBoxStyle.Exclamation)
|
||||
@ -1068,8 +1073,8 @@ LOGGER.Error(ex)
|
||||
End If
|
||||
|
||||
If INSERT_ACTIVE = True Then
|
||||
Dim sql As String = $"INSERT INTO TBPM_PROFILE_FINAL_INDEXING (PROFIL_ID, CONNECTION_ID, SQL_COMMAND, INDEXNAME, VALUE, ACTIVE, ADDED_WHO)
|
||||
VALUES ({profileId}, {connectionId}, '{sqlCommand}', '{indexName}', '{value}', {active}, '{addedWho}')"
|
||||
Dim sql As String = $"INSERT INTO TBPM_PROFILE_FINAL_INDEXING (PROFIL_ID, CONNECTION_ID, SQL_COMMAND, INDEXNAME, VALUE, ACTIVE, PREVENT_DUPLICATES, ALLOW_NEW_VALUES, ADDED_WHO)
|
||||
VALUES ({profileId}, {connectionId}, '{sqlCommand}', '{indexName}', '{value}', {active}, {preventDuplicates}, {AllowAddNewValues}, '{addedWho}')"
|
||||
|
||||
If ClassDatabase.Execute_non_Query(sql, True) Then
|
||||
INSERT_ACTIVE = False
|
||||
@ -1077,7 +1082,7 @@ LOGGER.Error(ex)
|
||||
Else
|
||||
Dim sql As String = $"UPDATE TBPM_PROFILE_FINAL_INDEXING
|
||||
SET CONNECTION_ID = {connectionId}, SQL_COMMAND = '{sqlCommand}', INDEXNAME = '{indexName}', CHANGED_WHO = '{addedWho}',
|
||||
VALUE = '{value}', ACTIVE = {active}
|
||||
VALUE = '{value}', ACTIVE = {active}, ALLOW_NEW_VALUES = {AllowAddNewValues}, PREVENT_DUPLICATES = {preventDuplicates}
|
||||
WHERE GUID = {guid}"
|
||||
|
||||
If ClassDatabase.Execute_non_Query(sql, True) Then
|
||||
|
||||
@ -307,7 +307,7 @@ Public Class frmFormDesigner
|
||||
pnldesigner.Controls.Add(chk)
|
||||
|
||||
Case ClassControlCreator.PREFIX_DATAGRIDVIEW
|
||||
Dim lc As LookupControl = ClassControlCreator.CreateNewLookupControl(cursorPosition)
|
||||
Dim lc As LookupControl2 = ClassControlCreator.CreateNewLookupControl(cursorPosition)
|
||||
|
||||
SetMovementHandlers(lc)
|
||||
|
||||
@ -752,8 +752,8 @@ Public Class frmFormDesigner
|
||||
|
||||
props = gridProps
|
||||
|
||||
ElseIf TypeOf sender Is LookupControl Then
|
||||
Dim grid As LookupControl = sender
|
||||
ElseIf TypeOf sender Is LookupControl2 Then
|
||||
Dim grid As LookupControl2 = sender
|
||||
Dim lookupProps As LookupControlProperties = CreatePropsObjectWithIndicies(New LookupControlProperties, row, Windream_VectorIndicies)
|
||||
lookupProps.MultiSelect = StrToBool(row.Item("MULTISELECT"))
|
||||
lookupProps.PreventDuplicates = StrToBool(row.Item("VKT_PREVENT_MULTIPLE_VALUES"))
|
||||
|
||||
@ -510,14 +510,14 @@ LOGGER.Error(ex)
|
||||
LOGGER.Error(ex)
|
||||
clsLogger.Add("Error in LoadSimpleData for Combobox: " & ex.Message)
|
||||
End Try
|
||||
ElseIf TypeOf control Is LookupControl Then
|
||||
ElseIf TypeOf control Is LookupControl2 Then
|
||||
Try
|
||||
Dim lookup As LookupControl = control
|
||||
Dim lookup As LookupControl2 = control
|
||||
|
||||
lookup.DataSource = dt
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
clsLogger.Add("Error in LoadSimpleData for Lookupcontrol: " & ex.Message)
|
||||
clsLogger.Add("Error in LoadSimpleData for LookupControl2: " & ex.Message)
|
||||
End Try
|
||||
ElseIf TypeOf control Is DataGridView Then
|
||||
Try
|
||||
@ -713,7 +713,7 @@ LOGGER.Error(ex)
|
||||
|
||||
Case "LOOKUP"
|
||||
LOGGER.Debug(" >> Versuch LOOKUP zu laden", False)
|
||||
Dim lookup As LookupControl = ClassControlCreator.CreateExistingLookupControl(oControlRow, False)
|
||||
Dim lookup As LookupControl2 = ClassControlCreator.CreateExistingLookupControl(oControlRow, False)
|
||||
|
||||
lookup.PreventDuplicates = oControlRow.Item("VKT_PREVENT_MULTIPLE_VALUES")
|
||||
lookup.AllowAddNewValues = oControlRow.Item("VKT_ADD_ITEM")
|
||||
@ -2268,9 +2268,9 @@ LOGGER.Error(ex)
|
||||
End If
|
||||
|
||||
End If
|
||||
Case "DigitalData.Controls.LookupGrid.LookupControl"
|
||||
Case "DigitalData.Controls.LookupGrid.LookupControl2"
|
||||
Try
|
||||
Dim oLookup As LookupControl = oControl
|
||||
Dim oLookup As LookupControl2 = oControl
|
||||
Dim oWindreamValue = aktivesDokument.GetVariableValue(oWMIndexName)
|
||||
|
||||
If IsNothing(oWindreamValue) Then
|
||||
@ -2289,7 +2289,7 @@ LOGGER.Error(ex)
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
LOGGER.Info(" - Unvorhergesehener Unexpected error in AddVorschlag_ComboBox - Indexname: " & oIndexName & " - Fehler: " & vbNewLine & ex.Message)
|
||||
MsgBox(ex.Message, MsgBoxStyle.Critical, "Unvorhergesehener Unexpected error in Add LookupControl:")
|
||||
MsgBox(ex.Message, MsgBoxStyle.Critical, "Unvorhergesehener Unexpected error in Add LookupControl2:")
|
||||
End Try
|
||||
|
||||
Case "System.Windows.Forms.DateTimePicker"
|
||||
@ -2458,7 +2458,7 @@ LOGGER.Error(ex)
|
||||
'If dr.Item("INDEXNAME").ToString.StartsWith("[%VKT") Then
|
||||
' Dim PM_String = Return_PM_VEKTOR(value, dr.Item("INDEXNAME"))
|
||||
'Hier muss nun separat als Vektorfeld indexiert werden
|
||||
If Indexiere_VektorfeldPM(value, dr.Item("INDEXNAME")) = False Then
|
||||
If Indexiere_VektorfeldPM(value, dr.Item("INDEXNAME"), dr.Item("PREVENT_DUPLICATES"), dr.Item("ALLOW_NEW_VALUES")) = False Then
|
||||
LOGGER.Debug(" >> FINALER INDEX '" & dr.Item("INDEXNAME").ToString & "' WURDE ERFOLGREICH GESETZT", False)
|
||||
Else
|
||||
errormessage = "Fehler beim finalen Indexieren:" & vbNewLine & idxerr_message
|
||||
@ -2708,47 +2708,42 @@ LOGGER.Error(ex)
|
||||
Return PM_String
|
||||
|
||||
End Function
|
||||
Private Function Indexiere_VektorfeldPM(input As String, NameVKTIndex As String)
|
||||
Private Function Indexiere_VektorfeldPM(input As String, NameVKTIndex As String, Optional PreventDuplicates As Boolean = False, Optional AllowAddNewValues As Boolean = True)
|
||||
Dim oOldValue As Object = aktivesDokument.GetVariableValue(NameVKTIndex)
|
||||
Dim oValueList As New List(Of Object)
|
||||
Dim oNewValue As Object()
|
||||
Dim oMissing As Boolean = False
|
||||
|
||||
Dim missing As Boolean = False
|
||||
Dim Anzahl As Integer = 0
|
||||
Dim myInputArr As String()
|
||||
'Jeden Wert des Vektorfeldes durchlaufen
|
||||
Dim wertWD = aktivesDokument.GetVariableValue(NameVKTIndex)
|
||||
If wertWD Is Nothing = False Then
|
||||
'Es wird gegen ein Vektorfeld nachindexiert
|
||||
If wertWD.GetType.ToString.Contains("System.Object") Then
|
||||
'es handelt sich um ein Vektorfeld - Zuweisen der Indexwerte des Vektorfeldes zu Array
|
||||
For Each obj As Object In wertWD
|
||||
If obj Is Nothing = False Then
|
||||
'Das Array anpassen
|
||||
ReDim Preserve myInputArr(Anzahl)
|
||||
'Den Wert im Array speichern
|
||||
myInputArr(Anzahl) = obj.ToString
|
||||
Anzahl += 1
|
||||
If oOldValue IsNot Nothing AndAlso TypeOf oOldValue Is Object Then
|
||||
' If new values are allowed, add the old values first
|
||||
If AllowAddNewValues Then
|
||||
oValueList = DirectCast(oOldValue, Object()).ToList()
|
||||
End If
|
||||
Next
|
||||
End If
|
||||
'Das Array anpassen
|
||||
ReDim Preserve myInputArr(Anzahl)
|
||||
'und den letzten Wert übergeben
|
||||
myInputArr(Anzahl) = input
|
||||
|
||||
' Add the new value
|
||||
oValueList.Add(input)
|
||||
Else
|
||||
'Das Array anpassen
|
||||
ReDim Preserve myInputArr(Anzahl)
|
||||
'und den letzten Wert übergeben
|
||||
myInputArr(Anzahl) = input
|
||||
' Just add input as the only value
|
||||
oValueList.Add(input)
|
||||
End If
|
||||
|
||||
If myInputArr.Length > 0 Then
|
||||
If PreventDuplicates Then
|
||||
oValueList = oValueList.
|
||||
Distinct().
|
||||
ToList()
|
||||
End If
|
||||
|
||||
oNewValue = oValueList.ToArray()
|
||||
|
||||
If oNewValue.Length > 0 Then
|
||||
'Jetzt die Datei indexieren
|
||||
If Indexiere_File(aktivesDokument, NameVKTIndex, myInputArr) = False Then
|
||||
missing = True
|
||||
If Indexiere_File(aktivesDokument, NameVKTIndex, oNewValue) = False Then
|
||||
oMissing = True
|
||||
errmessage = "Fehler beim Indexieren Vektorfeld '" & NameVKTIndex & "' - ERROR: " & idxerr_message
|
||||
End If
|
||||
End If
|
||||
|
||||
Return missing
|
||||
Return oMissing
|
||||
End Function
|
||||
Function Check_UpdateIndexe()
|
||||
Try
|
||||
@ -2780,9 +2775,9 @@ LOGGER.Error(ex)
|
||||
End If
|
||||
Dim Type As String = inctrl.GetType.ToString
|
||||
Select Case Type
|
||||
Case "DigitalData.Controls.LookupGrid.LookupControl"
|
||||
Case "DigitalData.Controls.LookupGrid.LookupControl2"
|
||||
Try
|
||||
Dim lookup As LookupControl = inctrl
|
||||
Dim lookup As LookupControl2 = inctrl
|
||||
|
||||
If lookup.SelectedValues.Count = 0 And _MUSSEINGABE = True Then
|
||||
missing = True
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user