LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

LabWindows Distribution Kit fails with Runtime Error

I've got a very simple application that uses the NI-488.2 driver to talk to a GPIB device.  I'm trying to build a distribution kit so I can move this application to another computer with a GPIB card (and drivers), but the distribution kit process crashes LabWindows about a quarter of the way through while it is working with the temp\template.ini file and displays an error message:
 
Microsoft Visual C++ Runtime Library                   <-- The title of the window
 
Runtime Error!
 
Program: C:\Program Files\National Instruments\CVI80\cvi.exe
 
This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.
 
 
When I click the 'OK' button, LabWindows quits.
 
This is a very simple application without any changes required.  I do have Microsoft Visual Studio 2005 Professional Edition loaded on this computer, but I'm not using it.
0 Kudos
Message 1 of 7
(4,562 Views)
Hi Brian,

I don't recall this problem coming up before, and it's not clear what's going on.  I'd ask that you produce and post a debug log by following the steps outlined in this post.  The log may give us some more specific information about the crash.  Also, please let me know what you have selected (with versions) on the Drivers & Components tab of the Edit Installer dialog, and whether your CVI version is 8.0 or 8.0.1.  I'll be happy to help sort this out with you.

Mert A.
National Instruments
0 Kudos
Message 2 of 7
(4,561 Views)

In the Drivers & Components Tab I deselected everything I didn't need and was left with only the 'Standard Run-Time' under 'LabWindows/CVI Run-Time Engine' and the 'NI-488.2 2.4.6' selected.  Clicking the 'Check Module Dependencies' button showed that I had everything I needed.

I'm running LabWindows 8.0.1.

I've got the debug file attached.

0 Kudos
Message 3 of 7
(4,555 Views)
Hi Brian,

I have a few more questions/tests. 

1. Does the crash happen every time you build this particular distribution?
2. During the build, do you ever see a dialog prompting you to insert a CD or locate a missing distribution?  If so, when does the crash happen in relation to this?
2. If you deselect NI-488.2, can you build without a crash?
3. Try building distributions that do not include NI-488.2 but include other drivers/components.  For example try Measurement and Automation Explorer, then with just the LabWindows/CVI Run-Time Engine (all subitems checked). Do you get a crash?
4. Backup CVI80\cvi.dll and replace it with the attached DLL.  After you build the distribution and get a crash, look for c:\bchase_debug.txt. Post it with your reply.

Thanks.

Mert A.
National Instruments
0 Kudos
Message 4 of 7
(4,530 Views)
1. Yes, the crash happens every time I build this distribution.
2. No, the distribution process does not prompt me to insert a CD or say it can't find something.  It always occurs as it is trying to copy template.ini.
3. My distribution originally included all of the sub items under the LabWindows/CVI Run-Time Engine, with the same crash results.  I tried deselecting everything I didn't need to see if one of those was the problem but it still crashed.  Deselecting the NI-488.2 2.4.6 cause the distribution to complain, because obviously it requires it for talking to the GPIB card, but it did build successfully.  Reselecting all of the Run-Time Engine subcomponents also builds successfully.  Adding Max at that point crashed LabWindows in exactly the same way as 488.
4. I replaced the cvi.dll file and got the debug file.  It's only a single line, so I'm not sure if it will help.  I'm attaching the file, but here it is:
 
MSIData::Build_CopyDistributions: Calling MDFDistCopyList_VerifyItemPresent
Should I try reinstalling the 488 drivers?  Could that be the problem?
 
Thanks for looking at this.
 
Brian
0 Kudos
Message 5 of 7
(4,518 Views)

I uninstalled the 488 libraries and reinstalled them, and then verified that the libraries could still find the 488 card.  It passed its self test.

Then I went in to see if I could build the distribution.  The 488 libraries no longer show up in the drivers and components tab, but when I clicked the 'Check for Dependencies' button it said that it had everything it needed.  All of the sub-functions under CVI were selected, but nothing else.  I tested to be sure that I could still send commands to my instrument, and it worked.  So I tried building a distribution, and it worked without crashing LabWindows.

I was able to install the software on my target machine, so I guess everything's fixed.  I just needed to reinstall the 488 drivers.  Very frustrating.

Thanks for your help and support, though.  I wouldn't have thought of trying to build the distribution without the 488 drivers, because I thought I needed them.  I don't understand why they disappeared from the list, though.

 

Brian Chase

0 Kudos
Message 6 of 7
(4,502 Views)
Hi Brian,

You can choose to distribute your application w/o the necessary drivers, though this requires that your target machines already have those drivers installed, or that someone installs them on those machines separately from your application.  When you deselect a needed driver from the Drivers & Components tab, you should get a warning to this effect.

The fact that NI-488.2 is no longer showing up in the list of available drivers indicates a problem.  It sounds like the driver installation is functional (it is usable and works properly), but certain files and/or registry keys that are necessary for building it into distributions were not installed.  For example, the file c:\Program Files\National Instruments\Shared\MDF\Manifests\NI-488.2 {XXXX...}.xml is likely missing.  I can try to help you get NI-488.2 back into a deployable state if you like.

Installing drivers separately from your application is a workaround, but it does not help us figure out what is actually wrong.  You will certianly have the same crash if you want to distribute other drivers besides NI-488.2 in future distributions.  I understand if you do not want to spend the time to debug this further, but if you do, I have attached another DLL with more debug output.  If you use this DLL, enable the debug logging (ctrl+shift+L), then try building a distribution with MAX included, I may be able to figure out where the crash occurs from the two debug logs (distBuildDebug.log and bchase_debug.txt).

Sorry for this drawn out process.  I know is it quite frustrating.

Mert A.
National Instruments
 
0 Kudos
Message 7 of 7
(4,493 Views)