Other Files Check Before Overwrite
Question:
When including Other Files in a compiled script is there a way to either suppress or check for the "other file" in the current directory and NOT overwrite the file? Currently, everytime I run the .exe it overwrites the Other File that was originally compiled and trashes any changes I have made to it.
Answer:
No way to chage it. Simply give the file a different name "somefile.ORIG" and when the script runs,
it looks and either copies SomeFile.ORIG to the desired spot (the first time) or leaves it also. So you
would modify the other file and leave somefile.orig alone and not copy it over. So then it does not matter
that somefile.orig gets overwritten each time.
You could try something like this:
Say your file is called "file1.txt". When you include it in the compile make sure it has a name of
something like "original_file1.txt". In your program you check for "file1.txt". If it doesn't exist
rename "original_file1.txt" to "file1.txt". Otherwise, delete "original_file1.txt".
Article ID: W16395
File Created: 2005:02:18:12:20:22
Last Updated: 2005:02:18:12:20:22