title: Currency Formatting with Delphi
body: <p>I am trying to writte a code in Delphi, which will be displaying a given number in currency format like this: </p>
  
  <p><img src="https://i.stack.imgur.com/1gnU3.jpg" alt="enter image description here"></p>
  
  <p>Now it works if filled whole number and another field until any paramater is updated.
  I'd be happy to have a code which would displaying a number in currency format as I writte it. I've tried to manage it by typing this:</p>
  
  <pre><code>procedure TForm1.EditZakladChange(Sender: TObject);
  var zaklad: Currency;
  begin
    zaklad := StrToFloat(EditZaklad.Text);
    EditZaklad.Text := FloatToStrF(zaklad, ffCurrency, 10, 2);
  end;
  
  end.
  </code></pre>
  
  <p>But everytime when someting is typed in (zaklad field), this error appears:</p>
  
  <p><img src="https://i.stack.imgur.com/xXZJB.jpg" alt="enter image description here"></p>
  
  <p>Could somebody help me with that, please?</p>