• 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
File size
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

File size


  • Subject: File size
  • From: Peter Mathiessen <email@hidden>
  • Date: Fri, 03 May 2002 16:00:07 +0200

Hi all,

Anyone how knows how to get the size (MB) of a file from the finder?

My script only give me some odd result.

The script:

copy "Macintosh HD:Script_folder:images_to_database:" as text to the_vol
set searchFolder to (the_vol & "in:")
set myList to list folder alias searchFolder without invisibles
repeat with myFilename in every item in myList
set theFile to alias (searchFolder & myFilename)
tell application "Finder"
get size of theFile
end tell
end repeat


-- result: 1.75208E+5

-- The size of the file is 172 K according to Finder.

Regards
Peter
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: File size
      • From: Andy Wylie <email@hidden>
    • Re: File size
      • From: email@hidden (Michael Sullivan)
  • Prev by Date: Excel: newby question
  • Next by Date: Re: Finder Whose by Modification date
  • Previous by thread: Re: Excel: newby question
  • Next by thread: Re: File size
  • Index(es):
    • Date
    • Thread