From 8fb214f5907de5a581899b66531ba676905e32de Mon Sep 17 00:00:00 2001 From: alexs75 Date: Tue, 18 Sep 2012 16:29:12 +0000 Subject: [PATCH] rxdbgrid - fix AV on open form whith empty grid git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@2516 8e941d3f-bd1b-0410-a28a-d453659cc2b4 --- components/rx/rxdbgrid.pas | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/rx/rxdbgrid.pas b/components/rx/rxdbgrid.pas index 70265b7a8..f447ff46b 100644 --- a/components/rx/rxdbgrid.pas +++ b/components/rx/rxdbgrid.pas @@ -2330,7 +2330,7 @@ begin begin F := GetFieldFromGridColumn(aCol); C := ColumnFromGridColumn(aCol) as TRxColumn; - if Assigned(C.FOnDrawColumnCell) then + if Assigned(C) and Assigned(C.FOnDrawColumnCell) then C.OnDrawColumnCell(Self, aRect, aCol, TColumn(ColumnFromGridColumn(aCol)), aState) else begin