• 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: How to coerce a real to an integer in X?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to coerce a real to an integer in X?


  • Subject: Re: How to coerce a real to an integer in X?
  • From: Michelle Steiner <email@hidden>
  • Date: Fri, 1 Feb 2002 11:49:56 -0700

On 2/1/02 10:46 AM, Bob.Kalbaugh <email@hidden> wrote:

>All-in-all, Your guess is probably way better than mine, but I think it is
>just AS helping us out in the first example. We're NOT using the "as"
>operator. And it's undocumented anywhere.

I've been fiddling with this. The only syntax that works is "integer
(number)" I tried "integer of number", and got an error. And, as you
found, "number as integer" also fails.

The following results are from the Event Log window:

script
integer (5.3)

tell current application
get integer "5.3"
--> 5
end tell

result
tell application "Claris Emailer"
integer ("5.3")
end tell


script
tell application "Claris Emailer"
integer ("5.3")
end tell

result
tell application "Claris Emailer" (ditto for BB Edit)
get integer "5.3"
--> 5
end tell

however...

script
tell application "Finder"
integer ("5.3")
end tell

result
tell application "Finder"
get integer "5.3"
--> Finder got an error: Can't get integer "5.3".

--Michelle

----------------------------------------------------------------------
| Michelle Steiner | We're not human beings having a spiritual |
| | experience. We're spiritual beings |
| email@hidden | having a human experience. |
----------------------------------------------------------------------


  • Prev by Date: Re: ACGI form parsing in OSX?
  • Next by Date: Re: How to coerce a real to an integer in X?
  • Previous by thread: Re: How to coerce a real to an integer in X?
  • Next by thread: Re: How to coerce a real to an integer in X?
  • Index(es):
    • Date
    • Thread