• 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: unreliability of NSWorkspace selectFile
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: unreliability of NSWorkspace selectFile


  • Subject: Re: unreliability of NSWorkspace selectFile
  • From: Matt Neuburg <email@hidden>
  • Date: Sat, 04 Mar 2006 17:56:46 -0800
  • Thread-topic: unreliability of NSWorkspace selectFile

On Fri, 03 Mar 2006 14:56:53 -0800, Matt Neuburg <email@hidden> said:
>I would like to reliably reveal *and* select a file/folder in the Finder.
>
>I am using [[NSWorkspace sharedWorkspace] selectFile:path
>inFileViewerRootedAtPath:folder].
>
>It isn't reliable. Sometimes it selects the file; sometimes it selects the
>containing folder instead. I've also tried issuing the command *twice*;
>sometimes this solves the problem (now it selects the file) and opens only
>one Finder window, other times it causes two Finder windows to open.
>
>Does this match the observations of others? I think I might be able to work
>around this by substituting Apple events, but it's more work, of course...
>m.

Just to follow up on this, I've substituted a "reveal" Apple event to the
Finder, and *that* didn't work consistently, and then I tried a "select"
Apple event to the Finder, and *that* didn't work consistently. In both
cases, every once in a while the containing folder would be selected instead
of the desired file, in column mode. So I conclude that this is a bug in the
Finder and its NSBrowser-like column view. m.

--
matt neuburg, phd = email@hidden, <http://www.tidbits.com/matt/>
A fool + a tool + an autorelease pool = cool!
AppleScript: the Definitive Guide - Second Edition!
<http://www.amazon.com/gp/product/0596102119>



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: Re: Connect NSView to NSDocument
  • Next by Date: Re: Nib XML format question
  • Previous by thread: Re: unreliability of NSWorkspace selectFile
  • Next by thread: Help In Drawing
  • Index(es):
    • Date
    • Thread