Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

European currency notation input problem with DBGrid.

Posted on 1998-12-03
1
1,086 Views
Last Modified: 2012-08-13
I use Delphi 1.0 for database apps.
Our country uses the european
currency notation so the number like
US$ 1,000.00 will show as US$ 1.000,00.
In TFloatField, the display format
",0.00" is used and it displayed without
problem in our Portuguese Windows 98.

When using the DBGrid, I could not input
the "," as point decimal. I tried to use
the MaskEdit property but it did not work
too. Besides that the delphi will let the
user to type various "," s so the delphi
will generate an exception in case the
user typed the comma 2 times like "45,,50"
instead of "45,50". I don't have problem
with DBEdit, because I download a freeware
DBEdit component to solve this problem.

Please help.
0
Comment
Question by:davichoi
1 Comment
 
LVL 2

Accepted Solution

by:
Thaddy earned 50 total points
ID: 1349169
If you look under 'CurrencyFormat' variable in he helpfile you'll see that you can change the behaveour by changing two Delphi global variables:

Set:
DecimalSeparator:=',';
ThousandSeparator:='.';

That's all, Your maskedits will now work for european formats.

0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question