6 Replies Latest reply on Aug 12, 2015 11:22 AM by basilisk2

    Active Non-printing buttons in Preview?



      Active Non-printing buttons in Preview?


      I followed the FMP Knowledge Base instructions for creating a script to generate a report using a sub-summary part on a layout. This creates the report in Preview mode. However, once in Preview mode my non-printing navigation buttons disappear. I could set the mode to Browse mode for the report, but is there no way that I can have non-printing navigation buttons in Preview mode? 

      I'm using FM Pro Advanced 11. Yes, I know there are Nav buttons in FMP14 but for various reasons I cannot upgrade to that yet.

      Can you please help?

        • 1. Re: Active Non-printing buttons in Preview?

          Short answer: No.  What kind of navigation buttons are they?  Ctrl and the up or down buttons will move from record to record. You could only stay in preview mode when the script is paused, then have the script either cancel or print thru a custom dialog.

          • 2. Re: Active Non-printing buttons in Preview?

            Thanks Steve, how would I code for that? I'm not good with scripting yet...

            • 3. Re: Active Non-printing buttons in Preview?

              Steve, sorry, I missed one of your questions...

              They are standard buttons that run scripts that take you to the different layouts I have created.

              • 4. Re: Active Non-printing buttons in Preview?

                It depends on your workflow and what you are trying to accomplish.  Does the report have to be viewed in Preview Mode, or does it look the same in Browse Mode?  Is the report created on one layout, then switched to another layout for printing?

                In the script that creates the report, the last step is probably:

                Enter Preview Mode [Pause] // with pause checked, the script is paused.

                Then when the user hits the enter key, or clicks continue if the menu bar is showing, to continue the script, you can add on whatever script steps to do whatever you want to do.  If you just use:

                Enter Browse Mode [ ] //pause not checked

                That could be the end of the script, sending you back to browse mode where your buttons are now visible.  Sometimes, the layout you use to create a report, isn't the layout you use to print a report.  In that case, you would add script steps to go back to the previous layout.

                Or, after your Enter Preview Mode [Pause] script step you can add:

                Show Custom Dialog ["Print?"; "Would you like to print this report?"] //Button 1= "Yes", Button 2= "No"

                Enter Browse Mode [ ]

                If [Get(LastMessageChoice)= 1 //"Yes"

                     Print Setup [ ] //set up your parameters

                     Print [ ]//set up your parameters

                End If

                Go to Layout [ ] //if you have to change layouts after printing.



                • 5. Re: Active Non-printing buttons in Preview?

                  Historical note:

                  Once upon a time, summary reports with sub summary parts could only be viewed in preview mode or printed. FileMaker 10 added the ability to see such Reports in Browse Mode. I would guess that this knowledge base report is very old and in need of updating as preview mode is no longer needed in order to view this type of report.

                  • 6. Re: Active Non-printing buttons in Preview?

                    Thanks guys, both of your last answers were extremely helpful. I shall now have another think about the workflow I want to use. It's nice to have options.

                    @Steve, I can use your script idea in other places too eg to Print; I've not used Show Custom Dialog before and now I can! Thanks! :-)

                    @Phil, now I know I don't have to use Preview mode I can now decide when and where I use it, which could save some coding! Thanks!