Autor Beitrag
sunshineh
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 44



BeitragVerfasst: Mi 10.12.08 21:45 
Hallo,
ich schreibe in ein txt-File Werte aus einem Integerarray wie folgt:
Write(datei, Array[J] );

Nun möchte ich mit Hilfe einer Variablen die Stellengenauigkeit einstellen, die die Integerwerte in dem txt haben sollen.
Wie kann ich das machen?
mkinzler
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 4106
Erhaltene Danke: 13


Delphi 2010 Pro; Delphi.Prism 2011 pro
BeitragVerfasst: Mi 10.12.08 21:49 
-Format()
-Trunc( <Wert> * <Geanuigkeit>)/<Genauigkeit>;

_________________
Markus Kinzler.
Martok
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 3661
Erhaltene Danke: 604

Win 8.1, Win 10 x64
Pascal: Lazarus Snapshot, Delphi 7,2007; PHP, JS: WebStorm
BeitragVerfasst: Mi 10.12.08 22:02 
Integerwerte sind Ganzzahlen. Die haben keine Nachkommastellen, von daher ist deine Frage irgendwie gegenstandslos...

_________________
"The phoenix's price isn't inevitable. It's not part of some deep balance built into the universe. It's just the parts of the game where you haven't figured out yet how to cheat."
sunshineh Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 44



BeitragVerfasst: Mi 10.12.08 22:07 
Sorry, sorry mein Fehler!!
Ich meine natürlich Float-Werte!
Gruß und Danke