19 Replies Latest reply on Oct 18, 2010 3:53 AM by Harbs.

    Scripting Fireworks

    Harbs. Level 6

      I have not been able to find a scripting forum for Fireworks, so please forgive me if this is the wrong forum...


      Some of you might have noticed the existence of Script Bay.


      It is a free panel for writing and running scripts and it works in  the many of the CS programs including Fireworks. It currently supports  ExtendScript and Javascript.


      As you might know, the only scripting language that Fireworks supports is Javascript. I am implementing AppleScript  support in Script Bay for InDesign, Illustrator, and Photoshop. These  apps have native support for these languages, so AppleScripts can be  used to control the apps.


      It is possible to enable support of AppleScript (and maybe VB) in  Flash and Fireworks as well, but such support would be of limited use,  because the app cannot be controlled as there is no built in support for  these languages. It would be possible to control external applications  (such as other CS apps, the Finder, system events, etc.). My question  is: would such functionality be useful or not?


      You can let me know your opinion using this really short survey.


      Any responses would be very much appreciated!




        • 1. Re: Scripting Fireworks
          heathrowe Most Valuable Participant

          Just the other day I was spreading the word about this on twitter.


          Great job with this. Nice to see Fw included in your Suite wide scripting capabilities.



          1 person found this helpful
          • 2. Re: Scripting Fireworks
            Harbs. Level 6

            Hi Heath,




            I saw a RT of your tweet. Great stuff!


            Do you think the AppleScript support would be useful?


            The only place I could see it being useful is as part of a workflow. i.e. you have a javascript then an applescript to do some post processing, and then maybe some other javascript doing something else...


            One of the nice things about Script Bay, is you can chain-execute scripts by putting them all in one folder, or simply selecting multiple scripts and runnning them...



            • 3. Re: Scripting Fireworks
              heathrowe Most Valuable Participant

              No problem. I actually dicovered your Panel deep into the Photoshop > Scripting forums, a few pages in. I was impressed, had to share it


              As for Applescript, I am not sure of it's popularity, unfortunately. Javascript has the more OS independant appeal for most users.


              One user oriented issue you may want to adjust. It took me quite awhile to 'understand' how to save a script from the panel. Everytime I would click Save nothing would happen. It was quite some time later that It downed on me that the active folder (in the tree view pane) would loose focus. If I drag/drop a script to the editor, the folder, I dragged from looses focus. If I make changes to the script in the editor and save, nothing happens, becuase a folder has to be selected in the tree view.


              It would be a great idea to have (somehow) a 'persistant' folder selected/active (until changed by the user), even if drag/drop is used, or the editor is used (in this case remember the last selected folder).


              A quick 'Reset/Clear' the default editor fields (Name,Script Window) would also be a handy feature.


              Otherwise great stuff.


              • 4. Re: Scripting Fireworks
                Harbs. Level 6

                Thanks for that!


                It's not supposed to lose focus like that. It's also supposed to save it to the default folder if nothing is selected. I'll look into these issues.


                Thanks for the suggestions!



                • 5. Re: Scripting Fireworks
                  Harbs. Level 6

                  For those interested, I've updated Script Bay to include AppleScript support (even for Flash and Fireworks!).



                  Heath, I fixed the issues you mentioned. Thanks! (The reset button is not there yet though...)



                  • 6. Re: Scripting Fireworks
                    heathrowe Most Valuable Participant

                    Super - much improved navigating the folder tree



                    • 7. Re: Scripting Fireworks
                      Michel Bozgounov Level 2

                      Hi, Harbs,


                      This sounds interesting -- and I dig that you included Fw/Fl support!

                      • 8. Re: Scripting Fireworks
                        John Dunning

                        Regarding Fireworks scripting forums, these two are the ones I typically look at:




                        1 person found this helpful
                        • 9. Re: Scripting Fireworks
                          Harbs. Level 6

                          Thanks John,


                          That's very good to know! (I'm not sure how I missed the one on Adobe's forums though...)



                          • 10. Re: Scripting Fireworks
                            Harbs. Level 6



                            I just took a peak at the stuff you've done. You've got some pretty amazing stuff!


                            I'd love to hear what you think of Script Bay from the perspective of an advanced Fireworks developer. Would you mind if I email you?



                            • 11. Re: Scripting Fireworks
                              John Dunning Level 1

                              Sure, you can ping me at fw at johndunning dotcom.  Script Bay looks interesting.

                              • 12. Re: Scripting Fireworks
                                heathrowe Most Valuable Participant

                                Harbs, I may have encountered a few issues:

                                - In TreeView, Add Script Folder

                                   Then Delete the Script Folder just previously added.


                                It literally deletes it from the drive! It should only remove the folder reference from the treeview.

                                I just learned this the hard way.


                                - Also, Deleting a Script folder deletes the contents of the Folder, but leaves the root Folder (as empty) in the treeview.


                                System Win Vista 32bit.



                                • 13. Re: Scripting Fireworks
                                  Harbs. Level 6

                                  Hi Heath,


                                  FYI, deleted files are not wiped from the hard drive. They are moved to the trash/recycle bin, so even if you remove them by mistake, you can restore them...


                                  Are you talking about root level folders, or sub-folders?


                                  Root level folders are added and removed using the flyout menu. ("Add Script Folder", and "Remove Script Folder" respectively.) This adds them to the list, and does not affect the file system.


                                  Sub-folders are added by right-clicking on a file or folder and selecting Add Folder. Sub-folders and files can only be added or removed from the FILE SYSTEM, there is no facilities to hide specific files or folders which are in one of your folders (except by filtering the file names). All folders and files with valid script extensions will always appear in the list.


                                  Do your observations fit with my explanation?


                                  Is removing sub-folders from the list something you'd want? How would you make it visible once it's hidden?


                                  FWIW, one of the things on my to do list is categorizing of scripts and filtering scripts by category...



                                  • 14. Re: Scripting Fireworks
                                    heathrowe Most Valuable Participant

                                    In my case, the files were 'hard' deleted.


                                    I added a script folder that resides on a networked shared folder on an external drive.

                                    When I went to access that folder, later, it was empty. The contents was no where to found (not in the Recycle Bin).


                                    I had to resort to 'undelete'/data recovery software  to retrieve it.



                                    • 15. Re: Scripting Fireworks
                                      Harbs. Level 6

                                      Ouch! That should not have happened...


                                      You are talking about a folder you added using the flyout menu. Correct?


                                      Maybe there's an issue with network drives. (Windows or Mac?) [Edit. Sorry, I see you already wrote Windows...] I'll definitely look into this ASAP! Data loss is the last thing we want!



                                      • 16. Re: Scripting Fireworks
                                        Michel Bozgounov Level 2

                                        As far as I know, deleting files and folders from remote (network) drives, removable flash cards, etc., cannot preserve deleted files in the Recycle bin (on Windows, at least). That's correct behaviour for the OS. So if I delete a file on my HDD, it will go to Recycle bin. If I connect to this machine over the network, though, removing the file will delete it, not place it in the Recycle bin...

                                        • 17. Re: Scripting Fireworks
                                          Harbs. Level 6

                                          Yes. That is true on Mac as well...


                                          That does make sense, but I don't want to assume user error too quickly though. I want to make 100% sure there's not a data-loss bug. I can't imagine how it would have deleted files, but strange bugs crop up sometimes...


                                          Even if there is no bug, I should at least add an additional warning before permanently removing files from a network drive...



                                          • 18. Re: Scripting Fireworks
                                            heathrowe Most Valuable Participant

                                            Thanks Michel for that confirmation.


                                            Harbs - a 'network' flag/check would be good, becuase otherwise it can still be an issue. As I thought, using the Remove Folder option from the panel flyout, would only remove the reference from the treeview within the Panel, and not have 'full' permission to source location.



                                            • 19. Re: Scripting Fireworks
                                              Harbs. Level 6

                                              I added some safeguards in the area of accidental deletion of files. I came up with an idea on how to handle network dirves more gracefully, but I still have to implement it...

                                              In the meanwhile, there's an interesting discussion going on over on the InDesign scripting forum about possible improvements to Script Bay. http://forums.adobe.com/message/3213272#3213272


                                              If anyone has any suggestions, please join in!