Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2010-03

TFloatField not accept comma as decimal separator

3 messages · 1 person · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Silvio Clecio

Please, see complete description on this link:

http://bugs.freepascal.org/view.php?id=15988 (including attached).

Hm... Is OnKeyPress again ??'

[]'s Silvio Cl?cio -- programmer ObjectPascal - Blog: http://blog.silvioprog.com.br programmer ObjectPascal - Site: http://www.silvioprog.com.br programmer ObjectPascal - Twitter: http://twitter.com/silvioprog -- grupo Lazarus-BR no Google - http://groups.google.com/group/lazarus-br/ -- Mensagem assinada com PGP Public Key, Ver.: GnuPG v1.4.9 (GNU/Linux)

Reply by email

Silvio Clecio
to Silvio Clecio
Silvio Clecio wrote 5 lines
Please, see complete description on this link: http://bugs.freepascal.org/view.php?id=15988 (including attached). Hm... Is OnKeyPress again ??'

I solved, the 'powerfull' solution:

(...)
procedure TDBEdit.KeyPress(var Key: char);
  function CanAcceptKey: boolean;
  begin
    case Field.DataType of
      ftFloat..ftBCD: Result := Key in ['0'..'9', '+', '-',
DecimalSeparator];
    else
      Result := Field.IsValidChar(Key);
    end;
    Result := Result and (Field.DataType  ftAutoInc);
  end;
var
  SavedKey: Char;
begin
(...)
[]'s Silvio Cl?cio -- programmer ObjectPascal - Blog: http://blog.silvioprog.com.br programmer ObjectPascal - Site: http://www.silvioprog.com.br programmer ObjectPascal - Twitter: http://twitter.com/silvioprog -- grupo Lazarus-BR no Google - http://groups.google.com/group/lazarus-br/ -- Mensagem assinada com PGP Public Key, Ver.: GnuPG v1.4.9 (GNU/Linux)

Reply by email

Silvio Clecio
to Silvio Clecio: Please, see complete description on this link:…
Silvio Clecio wrote 6 lines
Please, see complete description on this link: http://bugs.freepascal.org/view.php?id=15988 (including attached). Hm... Is OnKeyPress again ??'

Definitely resolved:

Thread:
http://www.lazarus.freepascal.org/index.php/topic,8894.0.html

Report:
http://bugs.freepascal.org/view.php?id=15988

Thxs to all :)

[]'s

Silvio Cl?cio

programmer ObjectPascal - http://silvioprog.com.br -- twitter - http://twitter.com/silvioprog -- Grupo Lazarus-BR no Google - http://groups.google.com/group/lazarus-br

Reply by email