12-15-2009 05:29 PM
I'm using MS with VC#. I have a NumericEdit that I'm using as a textbox. I want to display numbers in a very specific format:
0.0000123 as: 1.2E-5
If I use "Engineering Notation" formatting EE1, I get 12.3E-6. If I use "Scientific Notation" formating E1, I get 1.2E-005.
Is there any way to combine these? I don't want to snap to base 3 exponents, and I only want to display the minimum number of digits in the exponent.
For example, some numbers I want to see are 0.0E+0, 9.9E-15, etc.
Ideas?
Will
12-16-2009 05:40 PM
Hi Will,
Unfortunately I do not think you are going to achieve the exact format you are looking for without doing some customization. As you have found the Engineering Notation will only give us exponents that are a multiple of three, yielding anywhere from 1-3 values in front of the decimal point and with Scientific Notation, you will have the three digits in the exponent. There is no innate format to match your exact specifications.
12-22-2010 07:18 PM
When I use the formatting %.1e
I get numbers that look like 3.3E+1 not 3.3E+001
How do I get the formatting to give me the 3 digits in the exponent??
Thanks.
12-27-2010 03:23 PM
Where are you trying to enter this format string? It does not look like a numeric formatmode string. Are you using a Numeric Edit control?