• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: International number formats
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: International number formats


  • Subject: Re: International number formats
  • From: jj <email@hidden>
  • Date: Fri, 25 Feb 2005 14:32:02 +0100

> So it looks like AppleScript uses the English language number formats in
> some cases and Danish number formats in other cases, depending on what is
> getting coerced to what. Note that the 'thousand' seperator causes
> trouble.
>
> What is the intended/preferred behavior?

AppleScript uses only a dot as decimal separator (.). When you coerce
to/from string, though, it uses system's preferences (International pref
pane).

If you wanna coerce string to num, you must guess user's decimal separator,
then manipulate the input string (delete thousand separators and adjust as
needed the decimal separator). Eg:

set userDecimalSeparator to item 2 of (0.0 as string)


jj

--
http://www.macscripter.net/
http://www.osaxen.com/


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >International number formats (From: Brennan <email@hidden>)

  • Prev by Date: Re: International number formats
  • Next by Date: Re: International number formats
  • Previous by thread: Re: International number formats
  • Next by thread: Quark 6-Relinking picture when not there
  • Index(es):
    • Date
    • Thread