LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Which message file for the runtime engine is used by create distribution kit

i try to create lanuage specific distribution kits whith CVI 7.0. I want to use language specific message files (msgrt.txt) for the runtime engine. Wich files are used when creating a distribution kit?
0 Kudos
Message 1 of 3
(3,058 Views)
The message file that is used is distributed inside a merge module. We have 2 workarounds for this issues currently:

A. Summary: Include the translated file in the CDK under a different name, and use a batch file to copy it to the proper location at install time. This will work for CVI 6.0 and 7.0
----------------------------------------------------------------------------------------------------------------------------------------------------------------
A1. Name your translated msgrte.txt something like "msgrte.txt.tmp"

A2. Make a new file group in your CDK, include this new file, choosing the Group Destination to be "Windows System Directory", and the Relative Path to be: cvirte\bin

A3. Write a batch file that looks like this, and call it something like "fixup.bat":
REM The first two lines handle the difference between the system dirs in Win9X and WinNT/2000/XP
SET systemname=system32
IF EXIST %WINDIR%\win.com SET systemname=system
COPY /Y %WINDIR%\%systemname%\cvirte\bin\msgrte.txt.tmp
%WINDIR%\%systemname%\cvirte\bin\msgrte.txt

A4. Include this batch file in one of your file groups, and use the option under Advanced, and set this batch file to be the Executable to Run After Install.

NOTE: The limitation of this work around is that this will not work if a newer RTE is installed on the system. That is, the RTE logic included in the CDK is smart enough so that an older RTE will not overwrite a new one, but this batch file is not that smart - and will always overwrite the RTE message file with this one.

----------------------------------------------------------------------------------------------------------------------------------------------------------------
B. Summary: Include the translated file in the CDK, and edit the resulting MSI to instead use the new file. This will work for CVI 7.0 only.
----------------------------------------------------------------------------------------------------------------------------------------------------------------

B1. Create your translated msgrte.txt file, keeping this exact file name.

B2. Make a new file group in your CDK, include this new file, choosing the Group Destination to be "Windows System Directory", and the Relative Path to be: cvirte\bin.

B3. Open the built .MSI file using the Microsoft Orca tool (freely available in the Microsoft Installer SDK).

B4. Go to the table named File (list of tables on the left), and find a row that has the first column with the value MSGRTE.TXT. On this row, in the column Version (will be blank), put the number: 1.0
[This forces the CDK to always choose to overwrite the msgrte.txt file]

B.5 Go to the table named Component, and find the row that has the first column with the value MSGRTE.TXT. On this row, in the column named Attribute, change the value of 0 to this value: 16
[This forces the CDK to never uninstall this file, so that an uninstall of this CDK won't break anything]

NOTE: The limitation of this work around is that this will not work if a newer RTE is installed on the system. That is, the RTE logic included in the CDK is smart enough so that an older RTE will not overwrite a new one, but this edit is not intelligent - and will always overwrite the RTE message file with this one.

Additionally, this edit must be done every time the distribution kit is rebuilt.

Jeff
NI
Message 2 of 3
(3,058 Views)
Thank you Jeff,
this was the help I needed.

Thomas
0 Kudos
Message 3 of 3
(3,058 Views)