We have already said that you should use
MUST_INCLUDE rather than
INCLUDE, but we're always surprised that many developers never use include files at all. If the same code needs to be used in more than one place, it really should be in an include file.
Suppose that you have several documents that use
C:\QlikFiles\Finance\Budgets.xlsx and that the folder name is hardcoded in all of them. As soon as the file is moved to another location, you have several modifications to make, and it's easy to miss changing a document because you may not even realize it uses the file.
The solution is simple, very effective, and guaranteed to save you many reload failures.
Instead of coding the full folder name, create something similar to this:
Put the line into an include file—for instance,
Then, code this into each script:
Finally, when you want to refer to your
Budgets.xlsx spreadsheet, code the following...