Hi and welcome.
For a TEdit, go to properties and set number only to True.
For Combobox, on Keydown:
procedure TForm1.ComboBox1KeyDown(Sender: TObject; var Key: Word; Shift: TShiftState);
begin
if(Key >= 97) and (Key <= 106) then // 0->9
exit
else key := 0;
end;
If you just want to input number, there are TSpinEdit and TFloatSpinEdit in the "Misc" entry.
Happy coding, Pascal Lazarus is a great choice, I's free and your code will run on Windows, Linux and Mac
B->