Autor Beitrag
TimHa
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 88



BeitragVerfasst: Do 23.02.06 18:49 
Hallo zusammen!

Ich arbeite mit Delphi 6.0 Enterprise Edition. Wenn ich eine Variable vom Typ Curreny habe wird mir der Wert immer als DM angezeigt. Ich hätte den Wert viel lieber in Euro. :) Kann ich das irgendwo umstellen?

Tim
Gausi
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 8549
Erhaltene Danke: 478

Windows 7, Windows 10
D7 PE, Delphi XE3 Prof, Delphi 10.3 CE
BeitragVerfasst: Do 23.02.06 18:53 
Schau dir mal CurrencyString an ;-)

_________________
We are, we were and will not be.
TimHa Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 88



BeitragVerfasst: Do 23.02.06 19:07 
Die Delphi Hilfe antwortet mir hierauf:

CurrencyString legt das Währungssymbol (bzw. -zeichen) fest, das bei der Umwandlung von Gleitkomma- in Dezimalwerte verwendet wird. Der Anfangswert wird aus LOCALE_SCURRENCY abgerufen.

Wo ist denn dieses LOCALE_SCURRENCY?


Um mein Projekt kurz zu beschreiben: Ich addiere ein paar Zahlen, die in eine Datenbank geschrieben werden. Das Ergebnis soll vom Typ Currency sein. Müsste doch eigentlich klappen, oder?
UGrohne
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Veteran
Beiträge: 5502
Erhaltene Danke: 220

Windows 8 , Server 2012
D7 Pro, VS.NET 2012 (C#)
BeitragVerfasst: Do 23.02.06 19:18 
Geh einfach in die Systemsteuerung in die Regionsoptionen und stelle Deine Währung auf € um, fertig ;)
TimHa Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 88



BeitragVerfasst: Do 23.02.06 19:24 
Danke für den Tipp! Wäre ich nicht drauf gekommen.

Jetzt noch was zum Verständnis: Dieser Wert ist doch von Windows festgelegt oder? Ich frage deshalb, weil mein Programm mal auf anderen Rechnern installiert werden soll. Wäre ja für den Anwender doof, wenn er das von Hand umstellen müsste.

Warum ist der Wert eigentlich bei Windows XP noch auf DM? Sollte er nicht längst auf € umgestellt sein?

Gruß,
Tim
UGrohne
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Veteran
Beiträge: 5502
Erhaltene Danke: 220

Windows 8 , Server 2012
D7 Pro, VS.NET 2012 (C#)
BeitragVerfasst: Do 23.02.06 19:28 
Also bei mir ist er bei XP auch automatisch auf € eingestellt. Ich weiß nicht, warum nicht bei Dir.

Es gibt vielleicht noch die Möglichkeit, das über die Registry umzustellen. Der Key sCurrency liegt in HKCU\Control Panel\International
TimHa Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 88



BeitragVerfasst: Do 23.02.06 19:47 
So, hab es umgestellt und es hat alles funktioniert, d.h. das Programm sieht so aus, wie ich es haben möchte. :)

Danke für deine Hilfe. Hat mir viel Arbeit erspart! :)

Tim