if (not (key in ['0'..'9', #46, #8, #13])) then
key := #0;
if ((key in [#46]) and (pos('.', stringgrid1.Cells[stringgrid1.col, stringgrid1.row]) > 0)) then
key := #0;
for I := 1 to stringgrid1.RowCount - 1 do
begin
if pos('.', stringgrid1.cells[yourcol, i]) = 1 then
stringgrid1.Cells[yourcol, i] := '0' + stringgrid1.Cells[yourcol, i];
if pos('.', stringgrid1.cells[yourcol, i]) = length(stringgrid1.cells[yourcol, i]) then
stringgrid1.Cells[yourcol, i] := '0' + stringgrid1.Cells[yourcol, i] + '0';