Confuzzled Posted June 11, 2006 Share Posted June 11, 2006 Is there a UDF to convert numerics into a readable format so that commas can be shown?Example: Input is 123456.789 when formatted becomes 123,456.789If not, can we add a new flag 'c' to the inbuilt StringFormat function to facilitate adding these?(Issue: Internationalisation/Locale: Some countries use the decimal point for their digit grouping delimiter, so this may have to be extracted from the locale settings in Windows to decide)If not, is there a need for an UDF to do this? Is it more appropriate to put it on the Math, Misc, or String UDFs or should I roll my own?Comment: I found the examples and explanations in the StringFormat help page needed a bit of head scratching. Maybe a fuller example with more parts would be helpful. Link to comment Share on other sites More sharing options...
Daniel W. Posted June 11, 2006 Share Posted June 11, 2006 (edited) Func _komma( $num ) $number = StringReplace( $num , "." , "," ) Return $number EndFunc This should it be for komma replace Edited June 11, 2006 by Daniel W. --------------------------------------------------------------------------------------------------------------------------------Scripts : _Encrypt UDF_UniquePCCode UDF MS like calculatorInstall programm *UPDATED* --------------------------------------------------------------------------------------------------------------------------------[quote name='Helge' post='213117' date='Jul 26 2006, 10:22 AM']Have you ever tried surfing the internet with a milk-carton ?This is similar to what you're trying to do.[/quote] Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted June 11, 2006 Moderators Share Posted June 11, 2006 http://www.autoitscript.com/forum/index.ph...ndpost&p=155792 Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now