• 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
adding parameters to run command
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

adding parameters to run command


  • Subject: adding parameters to run command
  • From: Donald Hall <email@hidden>
  • Date: Sat, 23 Apr 2005 00:09:47 -0600

Title: adding parameters to run command
Is there any way to pass parameters to the run command of a script object?

e.g. This works:

script s1
      
on run
          display dialog "
script s1"
     
end run

end script

run s1

Event Log:
----------------------------------
tell current application
        display dialog "
script s1"
              {button returned:"OK"}
end tell
-----------------------------------

But this:

script s1
      
on run {p}
              display dialog "
script s1 " & p
end run
end script

tell s1 to run {"parameter"}

results in a syntax error: {"parameter"} doesn't understand the run message.

Note: I do not want to use the 'run script' scripting addition.

Thanks,

Don

--
Donald S. Hall, Ph.D.
Apps & More Software Design, Inc.
email@hidden
http://www.appsandmore.com
 _______________________________________________
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

  • Follow-Ups:
    • Re: adding parameters to run command
      • From: Paul Berkowitz <email@hidden>
  • Prev by Date: Re: The Pyramid - a challenge...
  • Next by Date: Re: ASCII code for pc return
  • Previous by thread: Re: ASCII code for pc return
  • Next by thread: Re: adding parameters to run command
  • Index(es):
    • Date
    • Thread