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

Re: q


  • Subject: Re: q
  • From: "F.C. Kuechmann" <email@hidden>
  • Date: Sun, 18 Oct 2009 18:57:57 -0700

thanx.


on run set diskName to "Foo" tell application "Finder" set diskSpace to (free space of disk diskName) end tell return diskSpace end run

Duh-oh! The above works. What if I want to pass diskName to the script from a prog?
This is what I've guessed at.


on Disco(diskName)
	tell application "Finder"
		set diskSpace to (free space of disk diskName)
	end tell
	return round (diskSpace / 1024 / 1024) as number
end Disco


On 17/10/2009, at 20:41:13 PM, Bruce Robertson wrote:

You probably figured it out by now;

 (free space of disk diskName)

On Oct 17, 2009, at 8:32 PM, F.C. Kuechmann wrote:

why doesn't this work?

on run
	set diskName to "Foo"
	tell application "Finder"
		set diskSpace to (free space of diskName)
	end tell
	return diskSpace
end run


_______________________________________________ Do not post admin requests to the list. They will be ignored. AppleScript-Users mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden
References: 
 >q (From: "F.C. Kuechmann" <email@hidden>)
 >Re: q (From: Bruce Robertson <email@hidden>)

  • Prev by Date: Re: Empty strings in XML-RPC struct replies
  • Next by Date: Re: Empty strings in XML-RPC struct replies
  • Previous by thread: Re: q
  • Next by thread: illustrator text box
  • Index(es):
    • Date
    • Thread