Translate copy profile strings, add icon to messagebox, remove inplace editor for regex & add ribbon button instead

This commit is contained in:
Jonathan Jenne
2021-01-12 15:15:07 +01:00
parent fcb1264bcd
commit 93f5588e48
7 changed files with 178 additions and 146 deletions

View File

@@ -35,11 +35,6 @@ Public Class ctrlApplicationAssignment
TBCW_PROF_REL_CONTROLTableAdapter.Connection.ConnectionString = MyConnectionString
End Sub
Private Sub ctrlApplicationAssignment_Load(sender As Object, e As EventArgs) Handles Me.Load
AddHandler RepositoryItemRegexEdit.ButtonClick, AddressOf RepositoryItemRegexEdit_Click
AddHandler RepositoryItemButtonEdit1.ButtonClick, AddressOf RepositoryItemRegexEdit_Click
End Sub
Public Function AssignProfileID(ProfileId As Integer) As Boolean
Try
SelectedProfileId = ProfileId
@@ -132,10 +127,10 @@ Public Class ctrlApplicationAssignment
Dim oRowHandle As Integer = oGridView.FocusedRowHandle
Dim oForm As New frmRegexEditor(oButtonEdit.EditValue)
If oForm.ShowDialog() = DialogResult.OK Then
oButtonEdit.EditValue = oForm.RegexString
End If
Console.WriteLine()
'If oForm.ShowDialog() = DialogResult.OK Then
'oButtonEdit.EditValue = oForm.RegexString
'End If
End Sub
Public Function Window_CreateAssignment(ProfileId As Integer) As Boolean
@@ -201,6 +196,24 @@ Public Class ctrlApplicationAssignment
End Try
End Function
Public Function Window_EditRegex() As Boolean
Try
Dim oRow = GridView_Window.GetDataRow(GridView_Window.FocusedRowHandle)
If oRow IsNot Nothing Then
Dim oRegex = oRow.Item("REGEX")
Dim oForm As New frmRegexEditor(oRegex)
If oForm.ShowDialog() = DialogResult.OK Then
oRow.Item("REGEX") = oForm.RegexString
End If
End If
Catch ex As Exception
Logger.Error(ex)
Return False
End Try
End Function
Public Function Control_Load() As Boolean
Try
TBCW_PROF_REL_CONTROLTableAdapter.Fill(MyDataset.TBCW_PROF_REL_CONTROL, SelectedWindowId)