MS kleine Dinge

This commit is contained in:
2020-11-09 17:38:43 +01:00
parent 88edadc816
commit 9f89961957
11 changed files with 267 additions and 143 deletions

View File

@@ -25,7 +25,7 @@ Public Class frmSearchStart
Private SEARCH_COUNT As Integer = 0
Private _Environment As Environment
Public Sub New(pDTSearchProfiles As DataTable)
Public Sub New(ByVal pDTSearchProfiles As DataTable, Optional ByVal pRunSearch As Boolean = False)
' Dieser Aufruf ist für den Designer erforderlich.
InitializeComponent()
@@ -263,6 +263,7 @@ Public Class frmSearchStart
oMyControl = oControls.CreateExistingDatepicker(oAttributeRow, oXPosition, oYPositionControl)
Dim myDTP As DateEdit = CType(oMyControl, DateEdit)
AddHandler myDTP.DisableCalendarDate, AddressOf DisableCalendarDate
AddHandler myDTP.EditValueChanged, AddressOf CalendarChanged
ElseIf oAttriTYPE = "BIT" Then
oMyControl = oControls.CreateExistingCheckbox(oAttributeRow, oXPosition, oYPositionControl)
Dim myCheckBox As CheckBox = CType(oMyControl, CheckBox)
@@ -407,7 +408,14 @@ Public Class frmSearchStart
' e.IsDisabled = True
'End If
End Sub
Private Sub CalendarChanged(sender As Object, e As EventArgs)
Dim myDTP As DateEdit = CType(sender, DateEdit)
If Not IsNothing(myDTP.EditValue) Then
Dim omydate = myDTP.EditValue.ToString
'Dim oInsert = $"EXEC PRIDB_NEW_USER_SEARCH_CRITERIA {PSEARCH_ID.ToString},{My.Application.User.UserId.ToString},{oAttrID.ToString},'{omydate}','{My.Application.User.UserName}'"
'My.DatabaseIDB.ExecuteNonQuery(oInsert)
End If
End Sub
Public Function IsValidDate(pCheckDT As DataTable, pDate2Check As Date) As Boolean
Dim oIsValid As Boolean = False
For Each oDateRow As DataRow In pCheckDT.Rows
@@ -746,6 +754,9 @@ Public Class frmSearchStart
End Function
Private Sub BarButtonItem4_ItemClick(sender As Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem4.ItemClick
Start_Search
End Sub
Private Function Start_Search()
Try
Dim oSEARCH_SQL = SEARCH_SQL
Dim oOperator As String
@@ -799,5 +810,13 @@ Public Class frmSearchStart
Catch ex As Exception
End Try
End Function
Private Sub frmSearchStart_KeyUp(sender As Object, e As KeyEventArgs) Handles Me.KeyUp
If e.KeyCode = Keys.F2 Then
Start_Search()
End If
End Sub
End Class