8 Replies Latest reply on Apr 29, 2016 3:12 PM by JJMack

    Vote on this: Add Quit event

    Pedro Cortez Marques Level 3

      I've posted on feedback.photoshop.com this idea:

       

      Add new event on QUIT

      I want to run a script when photoshop quits. When it triggers the event, it should quit in the end.

      When I mean running a script, I mean to be able to execute a bat/exe/cmd/etc external file that doesn't need photoshop to run.

      If there is a "quit" event on Bridge, why can't it exist on photoshop?

       

      Please vote on this:

      https://feedback.photoshop.com/photoshop_family/topics/add-new-event-on-quit

        • 1. Re: Vote on this: Add Quit event
          JJMack Most Valuable Participant

          Photoshop script event are triggered by Photoshop after  the event completes.  The why an event like document close is not very useful the document is no longer in Photoshop.  That means if there was an Application Quit event there would be not Photoshop around to trigger the event handler.  Since You do not want to be able to use Photoshop features in the event handler it seems to me you could create you own event handles outside of the script event manager.   Use Photoshop in a bat command when Photoshop quite control will return to the bat command file so run you event handler then.

          1 person found this helpful
          • 2. Re: Vote on this: Add Quit event
            SuperMerlin Level 5

            The quit event in Bridge is before it quits allowing you to do what ever you want, this is what is being requested for Photoshop.

            • 3. Re: Vote on this: Add Quit event
              JJMack Most Valuable Participant

              I understood what he was asking I just pointed out that in Photoshop event handlers are triggered after the event completes. That there would be no event manager around to trigger the event for Photoshop would have terminated the script event manager.  Some triggering task would need to see the Photoshop had completed and trigger the event handler.  I was suggesting a bat command waiting on Photoshop to complete could trigger his event handler. 

               

              I understood he was asking for a starting to quit event trigger. That event does not seem to exists and a quit event can not be triggered. I am sure users could also find uses for starting to close events.  So final change  can be made to the documents being closed.

              • 4. Re: Vote on this: Add Quit event
                xbytor2 Level 4

                What is needed is a 'PreQuit' event for PS and a 'PreClose' event for documents. ScriptUI has a way of registering event handlers for before and after something happens like a key press (iirc).

                • 5. Re: Vote on this: Add Quit event
                  Pedro Cortez Marques Level 3

                  Quit event or Pre-Quit event, whatever.

                  It works in Bridge, it should work in photoshop. Period.

                   

                  Its impossible? Then it can be done.

                  • 6. Re: Vote on this: Add Quit event
                    JJMack Most Valuable Participant

                    PreQuit and PreClose not possibly post close can be done with the script event manager Document Close event.  I would think a post quit event handler could be triggered if you run Photoshop within a command file. You do not seen to want to use anything that depend on being run within Photoshop. That can not be done for Photoshop just finished exiting.

                    • 7. Re: Vote on this: Add Quit event
                      Pedro Cortez Marques Level 3

                      Bridge does that and I'm using it.

                      The trigger functions when quits app and wait for my script before finally close Bridge.

                       

                      What I've requested it is simply to trigger the same way. Period.

                       

                      Close event its a doc event and not an app event. I've mentioned only quit event like the one in bridge.

                      • 8. Re: Vote on this: Add Quit event
                        JJMack Most Valuable Participant

                        We understand what you want a pre exit event like the Bridge has.  You submitted that request all I can say is do not hold you breath waiting for Adobe to implement your request they may or may not.  If they do implement your request it may not be for years.   If you need it now you need a way to implement it yourself. I was just suggesting a way that may work you.  If you wait for Adobe to provide the feature you most likely will have a long wait perhaps years.

                         

                        Adobe Photoshop plate is not emtpty.

                        Capture.jpg