• 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: Selecting a folder from the sidebar in a save dialog
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Selecting a folder from the sidebar in a save dialog


  • Subject: Re: Selecting a folder from the sidebar in a save dialog
  • From: CYB <email@hidden>
  • Date: Tue, 11 May 2010 18:14:00 -0500
  • Thread-topic: Selecting a folder from the sidebar in a save dialog

Title: Re: Selecting a folder from the sidebar in a save dialog
Jim, yes it make sense but would be nice if we can see your code, in order to try to help you in a much better way.

Carlos Ysunza
-----------------------------------
Carlos,

Thanks for your reply. I guess I didn't make myself clear enough. I don't see how hardcoding an alias solves my problem.

I am already GUI scripting Safari. I have to open a URL and find links on that page. To do that, I'm saving the source of the page (via GUI scripting -  command-option-U to view the source then command-S to save it). This creates a save dialog that I then use to name the file and select the location to save it. It just so happens that the location I want to save the file at is on the sidebar, so I can currently click it, via the command I showed earlier. These scripts have been working for me for a couple years now.

My dilemma is that I now need this script to work on two different operating systems (Tiger 10.4.11 and  Snow Leopard 10.6.3) where the dialog, specifically as it relates to picking the folder from the sidebar, is not the same. Not only that, but "To_Be_Sent", while it exists as a folder on both machines, is NOT in the same location. If "To_Be_Sent" is a sidebar item on both machines, the scripting should be similar, even if the folder is located on completely differently named drives on the two machines.

If I hard-code the path, I'll have to maintain separate versions of the script on each machine. But even at that, I don't see how to tell the save dialog to use that definition to save the file.

Does this make sense?

Jim

On May 11, 2010, at 1:56 PM, CYB wrote:



 Forget about GUI scripting, there is a much better and reliable solution to do what you want:
 Independently that you have your folder into the sidebar, this is just an alias, but the folder reside in some place into your hard disk so why you just don’t make something like this
 
 
set ToBesent to alias "MacPro:Users:username:Documents:MyFolder:"
 
Of course you need to change this using the real location of your folder
 
 
Carlos Ysunza B.
 Director
 Ysunza/Santiago
 Visual Communication • Automation
 Tel. (52)55 5256-0336
 email@hidden
 
 http://www.ysunzasantiago.com
 http://www.thesecretmexico.com
 http://www.softrobot.com.mx
   




Carlos Ysunza B.
Director
Ysunza/Santiago
Comunicación Visual • Automatización
Tel. (52)55 5256-0336
email@hidden

http://www.ysunzasantiago.com
http://www.thesecretmexico.com
http://www.softrobot.com.mx

 _______________________________________________
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

  • Follow-Ups:
    • Re: Selecting a folder from the sidebar in a save dialog
      • From: "Stockly, Ed" <email@hidden>
References: 
 >Re: Selecting a folder from the sidebar in a save dialog (From: Jim Brandt <email@hidden>)

  • Prev by Date: Re: Selecting a folder from the sidebar in a save dialog
  • Next by Date: Re: Selecting a folder from the sidebar in a save dialog
  • Previous by thread: Re: Selecting a folder from the sidebar in a save dialog
  • Next by thread: Re: Selecting a folder from the sidebar in a save dialog
  • Index(es):
    • Date
    • Thread