Variable that all scripts refer to
Posted: 29 Apr 2019, 18:50
Given i have placed the app „7-Zip“ and its executable file in the following save location:
„D:\7-Zip\7z.exe“
Furthermore I have a lot of scripts that refer to this path to add files to or extract files from an archive. Therefore i set a variable at the beginning of every of those scripts such as:
SevenZipAppExe := "D:\7-Zip\7z.exe "
Now if I change the save location of the 7-Zip-App, which I sometimes like to do, obviously all the scripts no longer find the save location and i would have to rewrite every single script to make them work again.
So for this purpose I need a way to easily change the reference point to the changed save location of the 7-Zip-App for all scripts.
I read a lot about global variables, the command #Include and IniRead and somehow I'm quite confused. And since I don’t have any experience with these tools I would be very happy and thankful if anyone could give me an advice what would be the best way to solve my described problem.
„D:\7-Zip\7z.exe“
Furthermore I have a lot of scripts that refer to this path to add files to or extract files from an archive. Therefore i set a variable at the beginning of every of those scripts such as:
SevenZipAppExe := "D:\7-Zip\7z.exe "
Now if I change the save location of the 7-Zip-App, which I sometimes like to do, obviously all the scripts no longer find the save location and i would have to rewrite every single script to make them work again.
So for this purpose I need a way to easily change the reference point to the changed save location of the 7-Zip-App for all scripts.
I read a lot about global variables, the command #Include and IniRead and somehow I'm quite confused. And since I don’t have any experience with these tools I would be very happy and thankful if anyone could give me an advice what would be the best way to solve my described problem.