jenssona Posted December 11, 2008 Report Share Posted December 11, 2008 I have an exe of a VI that we use to test air handling products at my work. Once a test is sucessfully completed, the VI prints 3 labels to a label printer. This all works fine. Recently, I tried adding an SMTP e-mail procedure to e-mail me this label (in an .xls file format) - this works, but also e-mail me a PDF of one of the graphs (all data gets sent to a blackberry phone as well, and that cannot open an .xls file formatted graph, the data is fine, but the graphs won't display). In the VI, using the "Print Report.vi" command, a pop-up will come up and ask me where I'd like to save my PDF, and this all works fine - it will e-mail me this file as well. BUT the pop-up never happens in the exe and the program gets an error when it trys to e--mail me this PDF file that doesn't exist (at least in the directory from which the exe is looking for it. Any advice? Thanks, Andrew Quote Link to comment
dblk22vball Posted December 11, 2008 Report Share Posted December 11, 2008 QUOTE at least in the directory from which the exe is looking for it. Do you know what directory that the .exe looking for the file?? You could just save the file there.... Also, check how you have the popup set up to "pop-up", it may not be configured properly or maybe you are not initializing the stop button and it is always set to true stopping the vi, ie closing it immediately??? Just throwing out ideas, I cant say too much without a picture or vi or more information. Quote Link to comment
Mark Smith Posted December 11, 2008 Report Share Posted December 11, 2008 QUOTE (jenssona @ Dec 10 2008, 07:18 AM) I have an exe of a VI that we use to test air handling products at my work. Once a test is sucessfully completed, the VI prints 3 labels to a label printer. This all works fine. Recently, I tried adding an SMTP e-mail procedure to e-mail me this label (in an .xls file format) - this works, but also e-mail me a PDF of one of the graphs (all data gets sent to a blackberry phone as well, and that cannot open an .xls file formatted graph, the data is fine, but the graphs won't display). In the VI, using the "Print Report.vi" command, a pop-up will come up and ask me where I'd like to save my PDF, and this all works fine - it will e-mail me this file as well. BUT the pop-up never happens in the exe and the program gets an error when it trys to e--mail me this PDF file that doesn't exist (at least in the directory from which the exe is looking for it.Any advice? Thanks, Andrew Andrew, Sure sounds like the app builder is removing the front panel for the Print Report.vi. If it's not set as a Startup VI in the build specification, then it gets its panel removed. Go to the Source File Settings in the App Builder and disable the Remove Front Panel for this VI (the Print Report.vi) and rebuild. This might be all you have to do. Mark Quote Link to comment
BrokenArrow Posted December 11, 2008 Report Share Posted December 11, 2008 Also be sure you use explicit paths, and especially not "current VI's path". Once you build an EXE, those paths may not mean anything if the program is on a different drive, machine, or folder. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.