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

Re: Scroll to top


  • Subject: Re: Scroll to top
  • From: "Bob.Kalbaugh" <email@hidden>
  • Date: Tue, 11 Sep 2001 15:20:12 -0500

on 9/11/01 12:35 PM, Robert Poland at email@hidden wrote:

> Wizards,
>
> I get tired of opening folders that are scrolled down to some
> arbitrary point. I'm trying to create a folder action script that
> will assure the folder opens to the top of the scrolling list.
> Haven't been able to find a command that should do this.
>
> Something like this -
>
> on opening folder this_folder
> scroll to top
> end opening folder
>
> TIA,

try something like this:

--

on opening folder ThisFolder
my setView(ThisFolder)
end opening folder

on setView(ThisFolder)

tell application "Finder"

activate

set view of window of folder ThisFolder to name
set sort direction of window 1 to normal

-- zooming the window should force the scroll to top
set zoomed of window of folder ThisFolder to true

-- if you don't want a full window, set your bounds (below is an example)
-- order is left side, top, right side, bottom of window
-- works on my 17 in. monitor
-- (remove the comment hyphens) in the line below

-- set bounds of window 1 to {5, 41, 614, 495}

end tell

end setView

--

save the script as a folder action and attach it to the folders you want it
to work with. A good example is the preferences folder

HTH.

--
bob.kalbaugh


  • Follow-Ups:
    • Re: Scroll to top
      • From: Robert Poland <email@hidden>
References: 
 >Scroll to top (From: Robert Poland <email@hidden>)

  • Prev by Date: Mac OS X and Simple Applescripting of Text Editors
  • Next by Date: Re: Mac OS X and Simple Applescripting of Text Editors
  • Previous by thread: Scroll to top
  • Next by thread: Re: Scroll to top
  • Index(es):
    • Date
    • Thread