Zum Hauptinhalt gehen

resize print image

Kommentare

4 Kommentare

  • Permanently deleted user
    Long,

     

    You may set the output image width/height based on your report's image control size along with the map DPI which is usually 96.

     

    For example, considiering that your .rpt (your report) has a Picture control whose size is 7 inch by 2 inch, and map_dpi - 96 to be exported, the image width and height on the 'Export Map', or 'Extract FeatureMap' activity on your workflow SHOULD set as 7 * 96 and 2 * 96.

     

    So I recomment you can set thw three configuration values: outWidthInch, outHeightInch and DPI, which are constant values, and then use them to set Image Width and Image Height to be exported for the report's data source.

     

    wish this helps you out.

     

    Munhwan
    0
  • Permanently deleted user
    Thanks Munhwan,

     

    I configured out by using C# script in workflow.

     

    cheers

     

    Long
    0
  • Justin Kraemer
    Long, would you be willing to share your C# script, please? I'm trying to resolve a scale issue in a report, and am thinking your code might help to lead me in the right direction.

     

    Thanks,

     

    Justin
    0
  • Permanently deleted user
    Hi Justin

     

    What I do is to resize the image file. Here are the steps

     

    1. DownloadImage 

     

    2. GetBytesFromImage

     

    3. Use C# script to save into web site

     

    System.Drawing.Size size = new System.Drawing.Size(450,300);

     

    System.Drawing.Bitmap oldImage = (System.Drawing.Bitmap)System.Drawing.Bitmap.FromStream(new System.IO.MemoryStream(tempByte));

     

    System.Drawing.Bitmap newImage = new System.Drawing.Bitmap(oldImage, size);

     

    newImage.Save("C:\\inetpub\\wwwroot\\TempFile\\NotificationImage.jpg");

     

    Hope it will be helpful

     

    cheers

     

    Long
    0

Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.