Fix error logs in SetControlValues_FromControl
This commit is contained in:
parent
c82eaf614a
commit
cbf4d6f892
@ -1490,36 +1490,33 @@ Public Class frmValidator
|
||||
Try
|
||||
oTextOption = oResultRow.Item("TextOption")
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
LOGGER.Debug("Column [TextOption] not found. Using Default of [Replace]")
|
||||
oTextOption = "Replace"
|
||||
End Try
|
||||
|
||||
Select Case oControl.GetType()
|
||||
Case GetType(TextBox)
|
||||
Try
|
||||
If oTextOption = "Replace" Then
|
||||
oControl.Text = oCaption
|
||||
Else
|
||||
oControl.Text &= oCaption
|
||||
If oTextOption = "Replace" Then
|
||||
oControl.Text = oCaption
|
||||
Else
|
||||
oControl.Text &= oCaption
|
||||
End If
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
End Try
|
||||
|
||||
Dim oColor
|
||||
Dim oBackColor
|
||||
Try
|
||||
oColor = Color.FromName(oResultRow.Item("BackgroundColor"))
|
||||
oControl.BackColor = oColor
|
||||
oBackColor = Color.FromName(oResultRow.Item("BackgroundColor"))
|
||||
oControl.BackColor = oBackColor
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
LOGGER.Debug("Column [BackgroundColor] not found. Using Default of [White]")
|
||||
oControl.BackColor = Color.White
|
||||
End Try
|
||||
|
||||
Dim oForeColor As Color
|
||||
Try
|
||||
oColor = Color.FromName(oResultRow.Item("FontColor"))
|
||||
oControl.ForeColor = oColor
|
||||
oForeColor = Color.FromName(oResultRow.Item("FontColor"))
|
||||
oControl.ForeColor = oForeColor
|
||||
Catch ex As Exception
|
||||
LOGGER.Error(ex)
|
||||
LOGGER.Debug("Column [FontColor] not found. Using Default of [Black]")
|
||||
oControl.ForeColor = Color.Black
|
||||
End Try
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user