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

Re: Another Applescript noob


  • Subject: Re: Another Applescript noob
  • From: "John C. Welch" <email@hidden>
  • Date: Thu, 27 May 2010 11:43:51 -0400
  • Thread-topic: Another Applescript noob

Title: Re: Another Applescript noob
On 5/27/10 10:40 AM, "Joy" <email@hidden> wrote:

I'm missing something in my applescript.

I've got the variables setup and the display dialogs seem to work, but the variables aren't being passed to the script correctly. Here's what I have so far for my applescript


property loginname : ""
display dialog "Enter your loginname without the container:" default answer loginname
set the loginname to text returned of the result
property department : ""
display dialog "Enter your Department:" default answer department
set the department to text returned of the result
do shell script ("echo " & loginname & department & " | /Users/gvsuadmin/Desktop/adbind.sh") user name "xxxx" password "xxxx" with administrator privileges

FYI, If they’re logged in, you can get the login name without them needing to enter it, unless the computer login name is different from the one you need:

set theSysInfo to system info
set loginname to theSysInfo's short user name

--
"There is no 'I' in TEAM."
US Navy SEALs
 _______________________________________________
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: 
 >Re: Another Applescript noob (From: Joy <email@hidden>)

  • Prev by Date: Re: Another Applescript noob
  • Next by Date: Re: Another Applescript noob
  • Previous by thread: Re: Another Applescript noob
  • Next by thread: Re: Another Applescript noob
  • Index(es):
    • Date
    • Thread