Scale Mode in Preview Control

Hi Alex,

we would like to set the scale mode property of the preview control programmatically.
For example to "fit to page" or "87%".
How to accomplish that? In the class reference we could not find a suitable property
or method.


Best Regards

Claus

Comments

  • edited 10:11PM
    Hello,

    It's a Zoom property, and ZoomIn, ZoomOut, ZoomPageWidth, ZoomWholePage methods of the PreviewControl.
  • edited 10:11PM
    OK, but how to apply? We used the code below, but preview windows didn't scale.

    frReport = new FastReport.Report();
    frReport.Load(sFilename);
    frReport.SetParameterValue(...);
    frReport.Preview = this.frPreview;
    frPreview.ZoomWholePage();
    frReport.Show();

    Used Version 1.0.56.0.

    Regards
  • edited 10:11PM
    Do it after preview:

    frReport.Show();
    frPreview.ZoomWholePage();
  • edited 10:11PM
    ... it didn't help!
  • edited 10:11PM
    I see; it is needed to do Application.DoEvents() before changing scale mode. I will fix it in the next build.

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.