Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: Issue with AS variable in OS 10.2
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Issue with AS variable in OS 10.2



On 3/24/05 8:54 AM, "Francois Houle" <email@hidden> wrote:

> Ok for some reason I re-wrote the script entirely and now it works... Go
> figure...
> A follow-up question on this though...
> Since the final output is in kb (added the -k option to the du command do to
> so), I then do this:
> set folder_sizemb to (folder_size / 1024) which works real well... except for
> the fact the I'd like it to output only one decimal after the period... Anyone
> have an idea how to "edit" this result ?
>
> Real, thanks to everyone who helps me out, your all great !

If you don't care if it rounds down every time (even when over x.x5...) then
this is easiest and fastest.

    set folder_sizemb to ((folder_size * 10) div 1024) / 10

--
Paul Berkowitz


 _______________________________________________
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: 
 >RE: Issue with AS variable in OS 10.2 (From: "Francois Houle" <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.