I have one TDBAdvGrid connected to TIBQuery and a TDBAdvNavigator, when I insert a new row and set the 'TAR' column value by code I have no problem, but if I try to change the value of this column (selecting the value from the drop down list) in the grid and post the value with Post button in navigator the system throw an exception saying the column value is null (value not accepted for this field), if I change the value and before to post I select an other column the exception doesn't throw. I have put the HideInplaceEdit() in BeforeAction event in Navigator.
object DBAdvGrid3: TDBAdvGrid
Left = 120
Top = 338
Width = 286
Height = 101
Cursor = crDefault
ColCount = 4
RowCount = 2
FixedRows = 1
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = []
Options = [goFixedVertLine, goFixedHorzLine, goVertLine, goHorzLine, goRangeSelect, goDrawFocusSelected, goRowMoving, goColMoving, goEditing]
ParentFont = False
ScrollBars = ssBoth
TabOrder = 19
OnEnter = DBAdvGrid3Enter
HoverRowCells = [hcNormal, hcSelected]
ActiveCellFont.Charset = DEFAULT_CHARSET
ActiveCellFont.Color = clWindowText
ActiveCellFont.Height = -11
ActiveCellFont.Name = 'Tahoma'
ActiveCellFont.Style = [fsBold]
ActiveCellColor = 9758459
ActiveCellColorTo = 1414638
AutoThemeAdapt = True
CellNode.TreeColor = clSilver
ColumnHeaders.Strings = (
''
'Tar'
'Dal'
'Tratt.'
'')
ControlLook.FixedGradientFrom = 16572875
ControlLook.FixedGradientTo = 14722429
ControlLook.FixedGradientHoverFrom = clGray
ControlLook.FixedGradientHoverTo = clWhite
ControlLook.FixedGradientDownFrom = clGray
ControlLook.FixedGradientDownTo = clSilver
ControlLook.DropDownHeader.Font.Charset = DEFAULT_CHARSET
ControlLook.DropDownHeader.Font.Color = clWindowText
ControlLook.DropDownHeader.Font.Height = -11
ControlLook.DropDownHeader.Font.Name = 'Tahoma'
ControlLook.DropDownHeader.Font.Style = []
ControlLook.DropDownHeader.Visible = True
ControlLook.DropDownHeader.Buttons = <>
ControlLook.DropDownFooter.Font.Charset = DEFAULT_CHARSET
ControlLook.DropDownFooter.Font.Color = clWindowText
ControlLook.DropDownFooter.Font.Height = -11
ControlLook.DropDownFooter.Font.Name = 'MS Sans Serif'
ControlLook.DropDownFooter.Font.Style = []
ControlLook.DropDownFooter.Visible = True
ControlLook.DropDownFooter.Buttons = <>
EnhRowColMove = False
Filter = <>
FilterDropDown.Font.Charset = DEFAULT_CHARSET
FilterDropDown.Font.Color = clWindowText
FilterDropDown.Font.Height = -11
FilterDropDown.Font.Name = 'MS Sans Serif'
FilterDropDown.Font.Style = []
FilterDropDownClear = '(All)'
FixedColWidth = 8
FixedRowHeight = 22
FixedFont.Charset = DEFAULT_CHARSET
FixedFont.Color = clWindowText
FixedFont.Height = -11
FixedFont.Name = 'Tahoma'
FixedFont.Style = [fsBold]
FloatFormat = '%.2f'
Navigation.AllowInsertRow = True
Navigation.AllowDeleteRow = True
Navigation.AdvanceAutoEdit = False
Navigation.InsertPosition = pInsertAfter
PrintSettings.DateFormat = 'dd/mm/yyyy'
PrintSettings.Font.Charset = DEFAULT_CHARSET
PrintSettings.Font.Color = clWindowText
PrintSettings.Font.Height = -11
PrintSettings.Font.Name = 'MS Sans Serif'
PrintSettings.Font.Style = []
PrintSettings.FixedFont.Charset = DEFAULT_CHARSET
PrintSettings.FixedFont.Color = clWindowText
PrintSettings.FixedFont.Height = -11
PrintSettings.FixedFont.Name = 'MS Sans Serif'
PrintSettings.FixedFont.Style = []
PrintSettings.HeaderFont.Charset = DEFAULT_CHARSET
PrintSettings.HeaderFont.Color = clWindowText
PrintSettings.HeaderFont.Height = -11
PrintSettings.HeaderFont.Name = 'MS Sans Serif'
PrintSettings.HeaderFont.Style = []
PrintSettings.FooterFont.Charset = DEFAULT_CHARSET
PrintSettings.FooterFont.Color = clWindowText
PrintSettings.FooterFont.Height = -11
PrintSettings.FooterFont.Name = 'MS Sans Serif'
PrintSettings.FooterFont.Style = []
PrintSettings.PageNumSep = '/'
SearchFooter.Color = 16572875
SearchFooter.ColorTo = 14722429
SearchFooter.FindNextCaption = 'Find next'
SearchFooter.FindPrevCaption = 'Find previous'
SearchFooter.Font.Charset = DEFAULT_CHARSET
SearchFooter.Font.Color = clWindowText
SearchFooter.Font.Height = -11
SearchFooter.Font.Name = 'MS Sans Serif'
SearchFooter.Font.Style = []
SearchFooter.HighLightCaption = 'Highlight'
SearchFooter.HintClose = 'Close'
SearchFooter.HintFindNext = 'Find next occurence'
SearchFooter.HintFindPrev = 'Find previous occurence'
SearchFooter.HintHighlight = 'Highlight occurences'
SearchFooter.MatchCaseCaption = 'Match case'
Version = '2.3.3.4'
AutoCreateColumns = True
AutoRemoveColumns = True
Columns = <
item
Borders = []
BorderPen.Color = clSilver
CheckFalse = 'N'
CheckTrue = 'Y'
Color = clWindow
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = []
HeaderFont.Charset = DEFAULT_CHARSET
HeaderFont.Color = clWindowText
HeaderFont.Height = -11
HeaderFont.Name = 'Tahoma'
HeaderFont.Style = []
PrintBorders = [cbTop, cbLeft, cbRight, cbBottom]
PrintFont.Charset = DEFAULT_CHARSET
PrintFont.Color = clWindowText
PrintFont.Height = -11
PrintFont.Name = 'Tahoma'
PrintFont.Style = []
Width = 8
end
item
Alignment = taRightJustify
Borders = []
BorderPen.Color = clSilver
CheckFalse = 'N'
CheckTrue = 'Y'
Color = clWindow
FieldName = 'TAR'
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = []
Header = 'Tariffa'
HeaderFont.Charset = DEFAULT_CHARSET
HeaderFont.Color = clWindowText
HeaderFont.Height = -11
HeaderFont.Name = 'Tahoma'
HeaderFont.Style = []
PrintBorders = [cbTop, cbLeft, cbRight, cbBottom]
PrintFont.Charset = DEFAULT_CHARSET
PrintFont.Color = clWindowText
PrintFont.Height = -11
PrintFont.Name = 'Tahoma'
PrintFont.Style = []
Width = 87
end
item
Borders = []
BorderPen.Color = clSilver
CheckFalse = 'N'
CheckTrue = 'Y'
Color = clWindow
Editor = edDateEdit
FieldName = 'DAL'
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = []
Header = 'Dal'
HeaderFont.Charset = DEFAULT_CHARSET
HeaderFont.Color = clWindowText
HeaderFont.Height = -11
HeaderFont.Name = 'Tahoma'
HeaderFont.Style = []
PrintBorders = [cbTop, cbLeft, cbRight, cbBottom]
PrintFont.Charset = DEFAULT_CHARSET
PrintFont.Color = clWindowText
PrintFont.Height = -11
PrintFont.Name = 'Tahoma'
PrintFont.Style = []
Width = 107
end
item
Borders = []
BorderPen.Color = clSilver
CheckFalse = 'N'
CheckTrue = 'Y'
Color = clWindow
ComboItems.Strings = (
'PC'
'PN'
'MP'
'BB')
Editor = edComboList
FieldName = 'TRATT'
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = []
Header = 'Tratt.'
HeaderFont.Charset = DEFAULT_CHARSET
HeaderFont.Color = clWindowText
HeaderFont.Height = -11
HeaderFont.Name = 'Tahoma'
HeaderFont.Style = []
PrintBorders = [cbTop, cbLeft, cbRight, cbBottom]
PrintFont.Charset = DEFAULT_CHARSET
PrintFont.Color = clWindowText
PrintFont.Height = -11
PrintFont.Name = 'Tahoma'
PrintFont.Style = []
Width = 41
end>
DataSource = ds_prentar
DataSetType = dtNonSequenced
EditPostMode = epRow
RefreshOnInsert = True
ShowUnicode = False
ColWidths = (
8
87
107
41)
RowHeights = (
22
22)
end