• 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: Play sounds via script
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Play sounds via script


  • Subject: Re: Play sounds via script
  • From: Christopher Stone <email@hidden>
  • Date: Sun, 03 Mar 2013 16:27:35 -0600

On Mar 03, 2013, at 12:23, Robert Poland <email@hidden> wrote:
The {-v option escapes me. This is one of many options I have tried.
______________________________________________________________________

Hey Bob,

Let's simplify that a bit.

set mantelSound to alias ((path to documents folder as text) & "Library Storage:Sound Library:Sounds from the Internet:all_systems_functioning.wav")
set mantelSound to quoted form of POSIX path of mantelSound

# Play at current system sound output level:
set cmd to "afplay " & mantelSound
do shell script cmd

# Play with the -v switch:
set _volume to output volume of (get volume settings)
set shellVol to (_volume / 10 / 2) as integer
set cmd to "afplay -v " & shellVol & " " & mantelSound
do shell script cmd

--
Best Regards,
Chris

 _______________________________________________
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: 
 >Play sounds via script (From: Robert Poland <email@hidden>)
 >Re: Play sounds via script (From: Luther Fuller <email@hidden>)
 >Re: Play sounds via script (From: Robert Poland <email@hidden>)
 >Re: Play sounds via script (From: Luther Fuller <email@hidden>)
 >Re: Play sounds via script (From: Robert Poland <email@hidden>)

  • Prev by Date: Re: Play sounds via script
  • Next by Date: Re: Play sounds via script
  • Previous by thread: Re: Play sounds via script
  • Next by thread: Re: Play sounds via script
  • Index(es):
    • Date
    • Thread