Re: Scroll to top
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