Re: Finder's insertion location
Re: Finder's insertion location
- Subject: Re: Finder's insertion location
- From: Lee Noble <email@hidden>
- Date: Thu, 3 Feb 2005 21:06:46 +0000
On Feb 3, 2005, at 16:08, rob ly wrote:
How am I able to move Finder's insertion location?
I would like it to move from it's default location to the inquiry field (ie magnifing icon - upperleft)
Bob Ly
I've no idea if this is possible. I spent the last few hours trying to solve it as a brainteaser. I've tried a couple of different methods but it seems impossible. Even with UI Scripting trying to click where the search box is doesn't work as far as I can tell.
Here's what I have. I'm trying to set the value of the text field. I'm definitely referring to the correct element but it won't have it.
Run this script and check out the event log in Script Editor. It seems to indicate that setting the value the way I am trying is impossible.
If you enter some text into the search field and then run the script you can see the value you have entered in the element properties but you can't change the properties.
I've tried setting it's focused to true, it's selected to true. None work.
Someone of course may run with what I've started and solve it for you. If you figure it out make sure you post it, it's bugging ME now!
tell application "Finder"
activate
set toolbar visible of window 1 to true -- to make sure that the metallic windows are in effect. Change to false to switch off
end tell
tell application "System Events"
tell process "Finder"
set searchBoxProps to properties of (button "Search" of tool bar 1 of window 1)
set searchBoxPos to position of (button "Search" of tool bar 1 of window 1)
click at {((item 1 of searchBoxPos) as integer) + 20, ((item 2 of searchBoxPos) as integer) + 20}
set theTextFieldProps to properties of (text field 1 of UI element 1 of button "Search" of tool bar 1 of window 1)
set the {value, name, title} of (text field 1 of UI element 1 of button "Search" of tool bar 1 of window 1) to {"something", "something", "something"}
end tell
end tell
_______________________________________________
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