diff --git a/ide/procedurelist.pas b/ide/procedurelist.pas index 962966629f..9e578afbd7 100644 --- a/ide/procedurelist.pas +++ b/ide/procedurelist.pas @@ -581,6 +581,9 @@ end; procedure TProcedureListForm.edMethodsKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState); begin + if LV.Items.Count = 0 then + Exit; + if Key = VK_Down then begin if (LV.Items.IndexOf(LV.ItemFocused) + 1) < LV.Items.Count then