Write in EXE-file

Is it possible to write information in the middle of the executive file, which run this program, and then read this information?
Alexey090397Asked:
Who is Participating?
 
peter_vcConnect With a Mentor Commented:
Sure this can be done, but I'm still not convinced that it's a good idea.  The trick is to define a string that serves as a marker.  Fill a string with ZZZ123ZZZ123 or some similar byte pattern.  Then scan the file looking for that sequence and replace it.  You will have to be carefull with the string length depending on if you use a string or a PChar.  When the program is run, it will see the new data as the string.
0
 
Alexey090397Author Commented:
Thank you, but if you think that it is not a good idea then help me where to I can write(hide)  2 real numbers. Please, show the working example of such program.
0
 
peter_vcCommented:
Write them to the registry (Win95) or a text file (any platform) and encypt them.  What are you trying to do?  Copy protection?  Registration codes?


0
All Courses

From novice to tech pro — start learning today.