LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Why does New Report.vi not always minimize the document?

I’m using Report Generation Toolkit for Microsoft Office to generate documents based on bookmarks in a template document. It works very well and I’m pleased with it. However, it usually (not always) opens up the template document and displays it while inserting the data in the various bookmarks. The process really slows down when this happens. The document is to automatically print to the default printer when the print button is clicked without opening up.

I’m using the New Report.vi with Window State set to Minimized, Report Type to Word and the template document’s path and file name sent to Template. All other settings are default.

After the bookmarks are inserted I use the Print Report, Dispose Report and Simple Error Handler vi’s. There are no errors displayed.

OS: XP-Pro
LV: v.7.1
Report Generation Toolkit: v.1.0.1
Word: Office 2003 (Office 2003 was installed before installing the Report Generation Toolkit.)

Thanks,
0 Kudos
Message 1 of 4
(3,259 Views)
Hello dj143,

I have tried to reproduce the behavior you are seeing and have been unsuccessful in seeing it. Could post a small VI with template that exhibits this behavior?

Another option you have is to use a WindowState input of no change in your New Report VI. This input will prevent word from showing word together.

Please let me know if you have any questions.

Regards,

Matt F
0 Kudos
Message 2 of 4
(3,241 Views)
Attached is a sample of the printing vi along with a subvi for support. Also attached is a sample template. This vi is a much simplified version of what I'm using. However, it also opens up the Word template. It opens and closes very quickly, but it should not open at all. In my final program, it really chokes up when the template opens.

I hope you can find something about it.

It's not clear to me what is meant by "WindowState input of no change."

Thanks,

Dave J.
0 Kudos
Message 3 of 4
(3,234 Views)

@dj143 wrote:
It opens and closes very quickly, but it should not open at all.



Hello Dave,

The behavior of Word opening and then minimizing is the expected behavior defined by Microsoft.

My apologies for the mention of no change as that was a feature added to version 1.1 of the toolkit. You can obtain the same behavior in your version by modifying the Word_Open VI VI in C:\Program Files\National Instruments\LabVIEW 6.1\vi.lib\addons\_office\_wordsub.llb\ to use a visible property of FALSE.

Please let me know if you have any questions.

Regards,

Matt F
0 Kudos
Message 4 of 4
(3,227 Views)