First responder of Tab View Item

Hi, I’ve got a tab view item with a few text fields. The first one is the one the cursor is in when I click on the tab. I’m working with the awake from nib handler. I’d like to put it in a different field…

if the name of the object is "mytab" then
	set first responder of tab view item "mytab" of tab view "tabs" of window "main" to text field "imagepath"
end if

That doesn’t work…and neither does this…

applescript]if the name of the object is “mytab” then
set first responder of of window “main” to text field “imagepath” of tab view item “mytab” of tab view “tabs” of window “main”
end if

OK, figured this one out from another post on this BBS. What a great resource this site is! Amazing!

So, how do you do it? I searched and I can’t find it. Perhaps the answer could be posted in this thread for posterity. Thanks.

The first responder is a property of a window, not a tab view item. As such try this…
set first responder of window “main” to text field “imagepath” of tab view item “mytab” of tab view “tabs” of window “main”