LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I redistribute an MFC project which uses the CVI DDE libraries ?

I have written a dialog-based MFC application, which includes a few CVI headers and static libraries for DDE support, and I'm thinking about the right way to redistribute it. At the moment, I expect to:

- Bundle the CVI DLL's in the program directory within my installer.
- Create a self-extracting Zip archive from C:\WINNT\SYSTEM32\cvirte\ and instruct users/customers to unpack it to the default directory. This folder merely contains a couple of fonts and some lists of error messages which my application may need to access from time to time.

I'd like to ask:

- Is this the most correct thing to do ?
Remember, I have built the project from within Visual Studio.NET - it's no use suggesting that
I "create a distribution kit from the CVI IDE".
- Is this going to be legal ?

Alternatives, please, if either answer is "No".

Yours

Pawel Tokarczuk
0 Kudos
Message 1 of 5
(3,630 Views)
The most correct solution would be to create a distribution using the Visual Studio .NET setup projects. This way you can pull the correct merge modules from [CVIDIR]\redist\msms and have everything installed the same way CVI installs it on your development machine.

If you tell me what libraries your are using in your application I can list the MSMs you should include in the setup project to get everything installed properly.

Jeff
NI
0 Kudos
Message 2 of 5
(3,630 Views)
Jeff,

My project (dialog-based, Visual C++) includes the following files:

cvidef.h
cvirte.h
ddesupp.h
cvirt.lib
cvisupp.lib

To get my application to work on a "foreign" machine, I have bundled the following
DLL's in the program directory:

cviauto.dll
cvibgi.dll
cviogl.dll
cvirt.dll
cvirte.dll
cvirtsup.dll
cvi_lvrt.dll
MFC71.dll
msvcr71.dll

I think the two groups of files came from folders labelled "msvc", under directories
named "extlib" and "redist" respectively. I'm a little vague now, because I have just
removed the demo version of CVI from my PC and not yet replaced it with the full licensed
version of the Developer Suite. But I would certainly know where to look in a fresh
installation.

I can't say that all the D
LL's are necessary; only that they are sufficient.

The zipped folder C:\WINNT\SYSTEM32\cvirte\ is necessary - in my arrangement -
to allow my application to display error messages correctly.

I hope that helps. I'd be grateful for a more machine-independent way to do this.
Obviously, I don't want to be giving away parts of my NI software illegally.
I know how to create a (simple) setup project from within Visual Studio.

Looking forward to hearing from you.

Pawel Tokarczuk
0 Kudos
Message 3 of 5
(3,630 Views)
Pawel,

Basically it looks like you should be OK with just CVIRTE support. You should include the following MSMs from "[CVIDIR]\redist\MSM" in your setup project to get the correct files on the machine. Do this by right clicking on the project and selecting "Add Merge Module...".

cvirte.msm
cvi_lvrt.msm
cvi_low_level.msm
instrsup.msm
NIMesaDLL.msm
NIMetaUtils.msm

Visual Studio should also warn you about other Merge Modules that are required by these. All the necessary merge modules should be found in the above directory.

This will also install the error message files so you will not need to include the zip file you mentioned earlier. Hopefully this will help you. Let me know if there is something more I can help with.

Jeff
NI
0 Kudos
Message 4 of 5
(3,630 Views)
Jeff,

Thanks very much - that looks quite definitive.
I shall try it over the next week or so, as my
project progresses. If I have any new problems,
I shall post a new question. Let's call this a
closed thread for now.

Yours

Pawel Tokarczuk
0 Kudos
Message 5 of 5
(3,630 Views)