Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Sonstige Fragen zu Delphi (https://www.delphipraxis.net/19-sonstige-fragen-zu-delphi/)
-   -   Delphi Format(); - String formatieren (https://www.delphipraxis.net/88147-format-%3B-string-formatieren.html)

EDatabaseError 10. Mär 2007 23:26


Format(); - String formatieren
 
Moin,
zu später Stunde stehe ich (mal wieder) richtig auf der Leitung.

Wie kann ich einen String bsp. 1 so formatieren das er danach so aussieht 001 ?

Irgentwie mit format(); aber ich komm gerade nicht auf die Syntax.

Mfg
Tobi

Muetze1 10. Mär 2007 23:26

Re: Format(); - String formatieren
 
Delphi-Quellcode:
Format('%.03d', [deineGanzzahl]);

EDatabaseError 10. Mär 2007 23:32

Re: Format(); - String formatieren
 
Super...Danke... :wall:

ich sollte glaube ich schlafen gehen.

Lannes 10. Mär 2007 23:58

Re: Format(); - String formatieren
 
Hallo,
Zitat:

Zitat von Muetze1
Delphi-Quellcode:
Format('%.03d', [deineGanzzahl]);

die Null ('%.03d') könnt ihr euch sparen, sie bewirkt nichts :wink:


Alle Zeitangaben in WEZ +1. Es ist jetzt 17:32 Uhr.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz