cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Johannes_T
Level 6

Constants in inx file

Hi folks,

I'm looking for a way to add constant strings in inx files.

Background: We identify the version of a file with a tool that searches in a file for a certain string (e.g. "Version") and everything behind this string represents the file version, for example: A file contains:
Version 1120B => The tool returns the version 1120B.

In IS3 it was possible to define a constant in a source file and this constant was available in the ins file. This seems to be impossible for inx files.

Does anyone have an idea, how this can be solved?
Thanks in advance.
Johannes
Labels (1)
0 Kudos
(3) Replies
joshstechnij
Level 10 Flexeran
Level 10 Flexeran

You should be able to do something like this:

#define STRING_CONST_NAME "Hello, world"


You can then use STRING_CONST_NAME anywhere a string value can be used.
0 Kudos
Johannes_T
Level 6

Thanks Josh for you response, but, it doesn't seem to work.

I added your example

#define STRING_CONST_NAME "Hello, world"

to my code, recompiled it and checked the inx file with a hex editor. Couldn't find the defined string. Any other ideas?

Edit:
I just compared two inx files I compiled from two rul files that differed in one character. I also found 2 bytes changed in the inx but can't interpret the byte as the original character.

Thanks.
Johannes
0 Kudos
joshstechnij
Level 10 Flexeran
Level 10 Flexeran

The inx file is encrypted so there won't be any readable strings in the file. The InstallScript engine decrypts the file at runtime before loading and running the script.
0 Kudos