3 Replies Latest reply on Jun 4, 2015 12:42 PM by philmodjunk

    Print Layout: Window Size

    rtolliver

      Title

      Print Layout: Window Size

      Post

      Question regarding controlling the window size of a print Report layout.  My script opens the layout but the window height and width are not correct, so I'm unable see the whole report.

      Can anyone tell me how to display the results of the functions Get(ScreenHeight) and Get(ScreenWidth)?

      Thanks

        • 1. Re: Print Layout: Window Size
          philmodjunk

          You might see if the Adjust WIndow [Resize to FIt ] option works for you first.

          To see the results of these fields:

          Put them in as watch expression in FMP Advanced's data viewer.

          Put them in unstored calculaiton field expressions and put the field on your layout.

          Use a script to show a custom dialog and put an expression into the custom dialog that uses these two functions to display window size.

          • 2. Re: Print Layout: Window Size
            rtolliver

            The Script step; Adjust Window [Resize to Fit] is in the original script and I'm not familiar with the use of FMP Advanced's Data Viewer.

            I'm not sure if I'm following the next part of your answer or not, I think I attempted what you've suggested with the custom dialog and it failed because I didn't know the proper script steps to input an expression.

            • 3. Re: Print Layout: Window Size
              philmodjunk

              You actually should use get ( windowwidth ) and get ( WIndowHeight ) if you want the dimensions of the current window rather than the monitor screen dimensions.

              IF you have FileMaker Advanced, you really need to learn how to use the data viewer as this is a very useful design and debugging tool.

              You can put Get ( WindowWidth ) & "|" & Get ( WindowHeight ) into the show custom dialog and when you run the script you'll get the window width and height separated by the | character. Other expressions are also possible.

              You can also define calculation fields with these functions and use storage options to specify that they be unstored calculations. Then you can just put them on your layout to show current window dimensions.