LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

print panel: wrong axis scale

I am using Print Panel to automatically get a copy of the graph produced on the front panel at the end of a run. The printed graph sometimes has an axis whose scale is wrong by a factor of 10 (in either direction). This happens to both the x- and y- axes but never both axes at the same time. The problem is sporadic.

The incorrect axes never appear on-screen. If the front panel is printed using File>Print after running, the axes are correct. Axis options AutoScale and Loose Fit are selected for both axes. The graph is an XY Graph with multiple plots.
Any insight?
0 Kudos
Message 1 of 5
(2,859 Views)
I have noticed that the print front panel has a timing issue. The time I
noticed it I had made a subvi just for the purpose of formatting some data
and printing it. The graph would sometimes come out blank if I did not put
in a delay.

"Sy" wrote in message
news:506500000008000000B75F0000-1031838699000@exchange.ni.com...
> I am using Print Panel to automatically get a copy of the graph
> produced on the front panel at the end of a run. The printed graph
> sometimes has an axis whose scale is wrong by a factor of 10 (in
> either direction). This happens to both the x- and y- axes but never
> both axes at the same time. The problem is sporadic.
>
> The incorrect axes never appear on-screen. If the front panel is
> printed using File>Print after
running, the axes are correct. Axis
> options AutoScale and Loose Fit are selected for both axes. The graph
> is an XY Graph with multiple plots.
> Any insight?
0 Kudos
Message 2 of 5
(2,859 Views)
Here is a program I wrote to advoid using the print panel. It saves the front panel to file then prints using IE. It works pretty well, but you may need to dig into the code to access some of IE's options.

Jeremy
0 Kudos
Message 3 of 5
(2,859 Views)
Once you suggested it, I saw that the graphs were being printed with new data on un-updated axes. I added a 10 ms delay before calling Print Panel, and that solved the problem.

Thanks.
0 Kudos
Message 4 of 5
(2,859 Views)
Useful comment. I had this problem with printing my front panel to a pdf file. I got rid of it by adding a delay before printing. Thanks!
0 Kudos
Message 5 of 5
(2,859 Views)