Measurement Studio for VB6

cancel
Showing results for 
Search instead for 
Did you mean: 

NIVisa and Visual studio 2005 setup program

Hi,

I work in a c# project that uses NationalInstruments.VisaNS.dll
version 8.1.20.222. The program works very well but when I tried to
get a Setup msi file using visual studio 2005, I had the following
error.-



----- Starting pre-build validation for project 'EMISetup' ------
WARNING: Unable to find dependency
'NATIONALINSTRUMENTS.COMMON' (Signature='4544464CDEAAB541'
Version='8.1.20.168') of assembly 'NationalInstruments.VisaNS.dll'
------ Pre-build validation for project 'EMISetup' completed ------
------ Build started: Project: EMISetup, Configuration: Debug ------
Building file 'C:\Documents and Settings\djamilabouzid\Desktop\EMI
\EMISetup\EMISetup\Debug\EMISetup.msi'...
ERROR: Unrecoverable build error
========== Build: 0 succeeded or up-to-date, 1 failed, 0 skipped
==========


Please, can any one helps me to find the problem.

Thank you very match,

Best regards,

Djamila Bouzid.

0 Kudos
Message 1 of 5
(8,258 Views)
Hi Djamila,
 
Unfortunately the error message is rather vague and could have been caused by many things. I do not see the error coming from the "Warning: 'NATIONALINSTRUMENTS.COMMON' ...". In fact, this warning also occurs when building the executable - it's safe to ignore this warning. The issue with the missing dependency (or versioning conflicts) of 'NATIONALINSTRUMENTS.COMMON' was discussed in this post.
 
To make sure that the COMMON or VISA assemblies are not the problem, I suggest to open and compile the SimpleReadWrite project (in C:\Documents and Settings\All Users\Documents\National Instruments\NI-VISA\Examples\DotNET2.0\SimpleReadWrite). This project makes use of 'NationalInstruments.VisaNS.dll' as-well. After compilation of the project, note the warning about 'NATIONALINSTRUMENTS.COMMON' - it's safe to ignore, the program should compile and run correctly. Now, add the executable created previously to a Setup Project. Compile the Setup project and note the same warning you received before about 'NATIONALINSTRUMENTS.COMMON' - the MSI should have however build successfully. Did you experience any errors?
 
If the previous project confirmed that the 'NATIONALINSTRUMENTS.COMMON' warning is not the cause of the error, then make sure that all dependencies and/or merge modules necessary to run your executable are included in your setup project.
 
Nestor
0 Kudos
Message 2 of 5
(8,235 Views)
Hi Nestor_G,

First, thank you for your answer.

I followed your suggestion, I opened the SimpleReadWrite project in
C:\Documents and Settings\All Users\Documents\National Instruments\NI-
VISA\Examples\DotNET2.0\SimpleReadWrite\cs.
I compiled the program, I run it. I built the solution. I added the
executable that I created previously to Setup project and then I built
the msi. But, I have the same error:

------ Starting pre-build validation for project 'EMISetup' ------
WARNING: Unable to find dependency
'NATIONALINSTRUMENTS.COMMON' (Signature='4544464CDEAAB541'
Version='8.1.20.168') of assembly 'NationalInstruments.VisaNS.dll'
------ Pre-build validation for project 'EMISetup' completed ------
------ Build started: Project: EMISetup, Configuration: Debug ------
Building file 'C:\Documents and Settings\djamilabouzid\Desktop\EMI
\EMISetup\EMISetup\Debug\EMISetup.msi'...
ERROR: Unrecoverable build error
========== Build: 0 succeeded or up-to-date, 1 failed, 0 skipped
==========


And my Build failed.

Regards,

Djamila.
0 Kudos
Message 3 of 5
(8,219 Views)

Odd Djamila,

If you empty the Setup project by removing all of its contents (should only be the executable from the previous example) and attempt to build - does it successfully generate the msi? If it fails, then there is obviously something wrong with the Visual Studio Installer - attempt a repair or reinstallation.

Nestor
0 Kudos
Message 4 of 5
(8,215 Views)
Hi Nestor_G,

Thank you for your help. I registered ole32.dll in my Pc and all work
very well.

Best regards,

Djamila.
0 Kudos
Message 5 of 5
(8,198 Views)