• 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: Quit-RelaunchFinder ( anErr = -600 procNotFound )
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Quit-RelaunchFinder ( anErr = -600 procNotFound )


  • Subject: Re: Quit-RelaunchFinder ( anErr = -600 procNotFound )
  • From: John Stiles <email@hidden>
  • Date: Wed, 16 May 2007 07:48:53 -0700

You can't send an appleevent to a process that doesn't exist.
Check MacErrors.h for descriptions of errors like "procNotFound".
Also, this is not a Cocoa question in any way. Try the Carbon list.


Francis Derive wrote:
Hello all!


I have a little app which start by quitting Finder ( thanks to Sample demonstrating quitting Finder at
http://developer.apple.com/technotes/tn2002/downloads/tn2062_2.hqx )


and I want it, at some point of the app, to re-launch Finder ( It helps :) ).

For this I have copy/pasted the code for QuitFinder() and thought it would be clever enough to change the constant kAEQuitApplication to the constant kAEOpenApplication.

This doesn't work.

Before I learn enough about these "AE" things, could anyone help ?

Francis


PS : I get anErr = -600 (procNotFound) in the debugger.

OSErr LaunchFinder() {
[...]
//Building the Apple event
anErr = AEBuildAppleEvent( kCoreEventClass,


            kAEOpenApplication,

typeApplSignature,
&kFinderProcessSignature,
sizeof(OSType),
kAutoGenerateReturnID,
kAnyTransactionID,
&tAppleEvent,
&tAEBuildError,
"");
if (noErr == anErr)
{
// Send the event.
anErr = AESend( &tAppleEvent, &tReply, kAENoReply |
kAEAlwaysInteract, kAENormalPriority, kNoTimeOut, nil, nil );
// always dispose of AEDescs when you are finished with them
(void) AEDisposeDesc(&tAppleEvent);
}
return anErr;
}
_______________________________________________


Cocoa-dev mailing list (email@hidden)

Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Quit-RelaunchFinder ( anErr = -600 procNotFound )
      • From: Francis Derive <email@hidden>
References: 
 >Quit-RelaunchFinder ( anErr = -600 procNotFound ) (From: Francis Derive <email@hidden>)

  • Prev by Date: Re: email verifier
  • Next by Date: Re: Trying to get folder path of a Finder window (Applescript anyone?)
  • Previous by thread: Quit-RelaunchFinder ( anErr = -600 procNotFound )
  • Next by thread: Re: Quit-RelaunchFinder ( anErr = -600 procNotFound )
  • Index(es):
    • Date
    • Thread