LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Question about printing an image/control Using Report Generator

The attached VI is an example of creating a report from a control or image. My problem is that when the control (xy graph) gets too large in the vertical direction it clips the image but, the horizontal is scaled to the width of the report. 

 

First question is why does it scale in the horizontal and not the vertical? See the Test.pdf for what I am talking about. 

Second, is it possible to control this behavior (edit/create an alternate for the Append Control Image to report or the Report VI's)?

 

I have found many work around but ultimately it comes back to; why automatically scale one direction but not the other?

For this application I don't mind that the graph is scaled down in the horizontal I just wish it would do the same thing in the vertical axis (I don't even want it to be a 1 to 1 zoom ratio, just fill the avalible report space).

 

Thoughts?

Download All
Message 1 of 8
(2,835 Views)

Not sure exactly what is going on but it appears to be something with the page dimensions. Switching the print orientation to portrait instead of landscape gives the whole graph. Are there any other workarounds you have found beside this one?

Rob S
Applications Engineer
National Instruments
0 Kudos
Message 2 of 8
(2,780 Views)

Rob, check that last page. Landscape does the same thing. 

 

The workarounds that I have found are resizing the graph before you get the image, resizing the image itself (by removing a % of pixels), or putting the image into a 2D Picture and resizing the 2D Picture control while zooming the picture that is displayed (zoom is both axis together).

 

So far all the work around methods have problems or limitations.

0 Kudos
Message 3 of 8
(2,728 Views)

I see what you mean about using the portrait style. I didn't note that the last page was the only one missing the numbers at the bottom. I'll continue to play around with the VI and see if I can find another workaround.

Rob S
Applications Engineer
National Instruments
0 Kudos
Message 4 of 8
(2,708 Views)

I see what you mean about using the portrait style. I didn't note that the last page was the only one missing the numbers at the bottom. I'll continue to play around with the VI and see if I can find another workaround.

Rob S
Applications Engineer
National Instruments
0 Kudos
Message 5 of 8
(2,704 Views)

I feel that most developers would want to maintain the horizontal-vertical zoom ratio but for me in this case I want to fill the available print area... I wonder what is allowing the horizontal to compress... and can that be duplicated on the vertical...

 

0 Kudos
Message 6 of 8
(2,694 Views)

I agree all of the workarounds have limitations. One workaround, that I'm not sure if you have tried yet is change the numeric constant from 50 to 20 (I attached a picture showing which constant I am talking about). This seems to fix the issue just because the image never becomes larger than the report page itself.

 

Let me know if that option creates any problems for you as well.

Kevin S
Applications Engineer
National Instruments
0 Kudos
Message 7 of 8
(2,663 Views)

Kevin,

 

Yea, that VI is just a test case and I needed a way to increment the size to demonstrate what I was talking about. 

The actual application is running on a computer with monitor with resolution of 1900x1200. The graph is the purpose of the application so it takes up 95% of the screen. So when I create an image it starts out to large for the report. 

 

Thanks for the thought. Sometimes it is the simple things that you don't think to try.

Ryan

0 Kudos
Message 8 of 8
(2,652 Views)