double to string
-
hi, i'm looking for a routine to convert double to string with at least a precision as the windows calculator does(32 digits after the comma)! does someone know such a function?? thx 4 help, IceMatrix
-
hi, i'm looking for a routine to convert double to string with at least a precision as the windows calculator does(32 digits after the comma)! does someone know such a function?? thx 4 help, IceMatrix
Sorry to dissapoint you, but the
double
datatype only supports 15 digits of precision. See http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclang/html/_langref_data_type_ranges.asp[^] for details. If you need more than that, you're going to have to roll your own. Anna :rose: Homepage | My life in tears "Be yourself - not what others think you should be" - Marcia Graesch "Anna's just a sexy-looking lesbian tart" - A friend, trying to wind me up. It didn't work. Trouble with resource IDs? Try the Resource ID Organiser Visual C++ Add-In -
Sorry to dissapoint you, but the
double
datatype only supports 15 digits of precision. See http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclang/html/_langref_data_type_ranges.asp[^] for details. If you need more than that, you're going to have to roll your own. Anna :rose: Homepage | My life in tears "Be yourself - not what others think you should be" - Marcia Graesch "Anna's just a sexy-looking lesbian tart" - A friend, trying to wind me up. It didn't work. Trouble with resource IDs? Try the Resource ID Organiser Visual C++ Add-InAnna-Jayne Metcalfe wrote: If you need more than that, you're going to have to roll your own. I didn't think you smoked ;P The tigress is here :-D
-
Anna-Jayne Metcalfe wrote: If you need more than that, you're going to have to roll your own. I didn't think you smoked ;P The tigress is here :-D
Only in the event of fire, fudge or extreme drunkeness. ;) Anna :rose: Homepage | My life in tears "Be yourself - not what others think you should be" - Marcia Graesch "Anna's just a sexy-looking lesbian tart" - A friend, trying to wind me up. It didn't work. Trouble with resource IDs? Try the Resource ID Organiser Visual C++ Add-In
-
Sorry to dissapoint you, but the
double
datatype only supports 15 digits of precision. See http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclang/html/_langref_data_type_ranges.asp[^] for details. If you need more than that, you're going to have to roll your own. Anna :rose: Homepage | My life in tears "Be yourself - not what others think you should be" - Marcia Graesch "Anna's just a sexy-looking lesbian tart" - A friend, trying to wind me up. It didn't work. Trouble with resource IDs? Try the Resource ID Organiser Visual C++ Add-In -
It probably uses a custom datatype or a third party library containing one. Do a search on the web and you should find something suited to your needs. It may not, however, be free. Anna :rose: Homepage | My life in tears "Be yourself - not what others think you should be" - Marcia Graesch "Anna's just a sexy-looking lesbian tart" - A friend, trying to wind me up. It didn't work. Trouble with resource IDs? Try the Resource ID Organiser Visual C++ Add-In
-
It probably uses a custom datatype or a third party library containing one. Do a search on the web and you should find something suited to your needs. It may not, however, be free. Anna :rose: Homepage | My life in tears "Be yourself - not what others think you should be" - Marcia Graesch "Anna's just a sexy-looking lesbian tart" - A friend, trying to wind me up. It didn't work. Trouble with resource IDs? Try the Resource ID Organiser Visual C++ Add-In
float f; double d; f = 3.1415926535897932384626433832795f; d = 3.1415926535897932384626433832795; printf( "%.32f\n", f ); printf( "%.32lf\n", d ); Output: 3.14159274101257320000000000000000 3.14159265358979310000000000000000 double has to be more precise, but the function doesnt show it!
-
try this:
double dFoo = 41.1325934653849974801841984193481498319048193849
char string[256];
sprintf("%d.32", dFoo);regards