LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

code calls Word, exe doesn't

Solved!
Go to solution

the program generates a MS Word report using NI_report.lvclass VIs

in code this is working fine but I built and exe and it doesn't do anything when I press the button. (actually the finger changes to an hourglass for a split second)

 

on the Source Files pane of the build spec, in the "Always Include" panel I have  

_Excel Dynamic VIs.vi  and _Word Dynamic VIs.vi

is there something else I must include?

 

thanx

lmd2 

Lawrence M. David Jr.
Certified LabVIEW Architect
cell: 516.819.9711
http://www.aleconsultants.com
larry@aleconsultants.com
0 Kudos
Message 1 of 19
(4,356 Views)
Just a thought but could it be a pathing issue of some sort?


Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
0 Kudos
Message 2 of 19
(4,355 Views)
the path comes from a tree control, independent of where the exe is located - but I just double checked in case, I don't think that's it, but thanks
Lawrence M. David Jr.
Certified LabVIEW Architect
cell: 516.819.9711
http://www.aleconsultants.com
larry@aleconsultants.com
0 Kudos
Message 3 of 19
(4,345 Views)

Are you using error handling when you call the code to generate the Word Document?  If so, are you getting any specific error?  Is the EXE running on the same system as the source?  If not, is the version of Word for development the same as on the EXE machine? 

0 Kudos
Message 4 of 19
(4,327 Views)

there was error handling but some newer subVIs were not in the loop, just corrected that. same machine same version of office, will update this post when I run the new exe

 

 

Lawrence M. David Jr.
Certified LabVIEW Architect
cell: 516.819.9711
http://www.aleconsultants.com
larry@aleconsultants.com
0 Kudos
Message 5 of 19
(4,322 Views)

ok getting error 7  occurred at Get LV Class Default Value.vi

 

looks like I'm missing some input

thanx everyone

should be able to find this (I hope)

 

 

Lawrence M. David Jr.
Certified LabVIEW Architect
cell: 516.819.9711
http://www.aleconsultants.com
larry@aleconsultants.com
0 Kudos
Message 6 of 19
(4,317 Views)

hope someone is still out there

 

 I inherited this project which was originally written in LV 7.1 and has been updated to 8.6.1

in the project I see that some report VIs (Initialize Word Report.vi, Write Image to Word Report.vi, etc.) are flagged missing or moved

looking at the new report VIs (class) these have changed (yet this works in code)

so now the question is how to repair or re-link or something ... 

help will be greatly appreciated

 

thanx

lmd2 

Lawrence M. David Jr.
Certified LabVIEW Architect
cell: 516.819.9711
http://www.aleconsultants.com
larry@aleconsultants.com
0 Kudos
Message 7 of 19
(4,312 Views)

Initialize Word Report.vi and Write Image to Word Report.vi are not part of the Report Generation toolkit.  It sounds like you had some custom VIs in LabVIEW 7.1 that you'll need to find and move over to 8.6.1.

0 Kudos
Message 8 of 19
(4,279 Views)

well I think the present code doesn't need these VIs at all, rather the issue (I think) is that they were never removed from the project (now that native toolkit VIs are used)

and it seems that though the code doesn't use or need them, just having them listed in the project (although missing) is causing the EXE to not work

does that make sense?

 

Lawrence M. David Jr.
Certified LabVIEW Architect
cell: 516.819.9711
http://www.aleconsultants.com
larry@aleconsultants.com
0 Kudos
Message 9 of 19
(4,270 Views)
I don't see any reason why their presence in the project would cause your build to fail, unless they are included somewhere in the build.  I recommend removing them from the project.  The only VIs you should need to include in Always Included are the _Word Dynamic VIs.vi and _Excel Dynamic VIs.vi that you already mentioned.  Also, double-check that the only thing on each of their diagrams is the NI_Word.lvclass and NI_Excel.lvclass class constants, respectively.
0 Kudos
Message 10 of 19
(4,264 Views)