LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Saving report to PDF without Word Licence

Solved!
Go to solution

Hello again

 

This time i'm trying to create a PDF report. On my computer i have full office licence and it works without a problem, however the application is meant for computers which don't always have licences installed.

 

In both cases i used the examples provided (LabVIEW PDF Reports), but on a computer without a licence it gets stuck, because word opens with "Install licence" warning. Manually i can bypass this warning and save as PDF, but VI itself can't do that so it fails.

 

Since word licence seemed to be a problem i then tried to create an HTML report and save it as PDF using print to pdf function, but it also failed. This time no error was given, but a "Pick an account to sign in with" screen showed up.

 

Is there any way to create a report and save it to PDF without word licence or is Microsoft just so stuck up with their licences that it's impossible?

 

AeroSoul_0-1600166123129.png

AeroSoul_1-1600166168263.png

 

0 Kudos
Message 1 of 12
(2,588 Views)
Solution
Accepted by AeroSoul

https://www.carya.nl/products/pfd-toolkit-labview/

 

But you'll have to start over with the report generation code.

Message 2 of 12
(2,583 Views)

Not exactly what i had in mind but upon further googling i found out you can't use RGT without word licence, so it's the next best thing.

 

I also found this thread, where there are some other possible solutions.

 

Thank you for your help, it's a very nice tool from what i tried it 🙂

0 Kudos
Message 3 of 12
(2,506 Views)

Thanks!

 

At some point I might make a RGT Child, so the RGT can be used to make PDF Toolkit PDF's.

0 Kudos
Message 4 of 12
(2,496 Views)

I guess one solution would be to create a HTML-report and use Print to PDF. You should have some Virtual printer per default, or you'll have to install some PDF-writer.

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 5 of 12
(2,491 Views)

@Yamaeda i tried that and got the second error "sign in your microsoft account" thing.

0 Kudos
Message 6 of 12
(2,480 Views)

All the examples seem to work for me, however i can't get it to work with my picture.

 

I used example code and just modified to take front panel picture of a VI i'm using.

The picture is drawn in labview so i know that works ok, but for some reason the PDF just comes out blank (teal rectangle from example is still drawn). When opening pdf i also sometimes get an error that "something is wrong".

 

Any advice on what i'm doing wrong?

 

Block diagram:

AeroSoul_0-1600348224861.png

Front panel:

AeroSoul_1-1600348273200.png

 

 

0 Kudos
Message 7 of 12
(2,477 Views)

PDF Insert Picture Control.vi is very tricky. There's not really a way to get all the information from LabVIEW or the control to replicate it. This is a very indirect way to embed an image. Not sure why it wouldn't work though.

 

Can you try PDF Insert Pixmap.vi or PDF Insert Pixmap As JPG.vi instead?

 

Also, PDF Get Toolkit Info returns a version. Can you check it? It should be at least V2.1.

0 Kudos
Message 8 of 12
(2,468 Views)

The version is v2.1b10.

 

I could not get the insert picture to work, but insert pixmap and insert pixmap as jpg did work. You need to specify the size of image or it doesn't work tho.

 

Scaling images to shrink to A4 page returns kind of crappy results, but that's on Labview.

 

Thanks for your help again 🙂

 

Ps.: attaching the VI from which i tried to capture front panel, to capture it i just used default example for insert picture with dimensions changed a bit.

0 Kudos
Message 9 of 12
(2,402 Views)
Solution
Accepted by AeroSoul

Insert functions need a size, or it will add the images, but not make them visible.

 

This is useful if you want to add an image more then once. The image is added, and you can get it's name, and then add the name more then once. This prevents adding the binary data of the image each time.

 

The attach functions might work better for. It's probably more like the RGT. Each attach function simply adds to the page, and (optionally) proceeds to the next page if it doesn't fit. Less control, so that's why the insert functions are there. You can insert stuff, and attached text will wrap around it. 

 

You can scale up the LabVIEW image (or a copy of it) before getting an image to get a higher resolution.

 

There's an example on adding a graph as vector graph. It's not too hard to adapt to specific graphs. It's near impossible to provide all functionality as a sub VI. That's why it's in examples. Depending on the data, this might shrink or grow your PDF size dramatically. The image will always be X*Y, the data can be anything from 0 to Inf samples...

Message 10 of 12
(2,397 Views)