Fix error with missing columns in CTRL placeholder
This commit is contained in:
parent
1d5c577d2b
commit
235ce4818a
@ -197,6 +197,8 @@ Public Class clsPatterns
|
||||
oColumnName = oSplitName.Last()
|
||||
End If
|
||||
|
||||
LOGGER.Debug("Found placeholder for control [{0}].", oControlName)
|
||||
|
||||
Dim oControl As Control = oPanel.Controls.Find(oControlName, False).FirstOrDefault()
|
||||
|
||||
If oControl IsNot Nothing Then
|
||||
@ -233,13 +235,13 @@ Public Class clsPatterns
|
||||
Where(Function(c) c.FieldName = oColumnName).
|
||||
SingleOrDefault()
|
||||
|
||||
If oColumn Is Nothing Then
|
||||
If oColumn?.SummaryItem?.SummaryValue Is Nothing Then
|
||||
LOGGER.Warn("Column [{0}] not found in Grid!", oColumnName)
|
||||
oReplaceValue = ERROR_REPLACE_VALUE
|
||||
Else
|
||||
oReplaceValue = oColumn.SummaryItem.SummaryValue
|
||||
End If
|
||||
|
||||
oReplaceValue = oColumn.SummaryItem.SummaryValue
|
||||
|
||||
Case Else
|
||||
oReplaceValue = ERROR_REPLACE_VALUE
|
||||
End Select
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user