$compilestatus
Welcome to our Knowledge Base
Documentation | Blog | Demos | Support
< All Topics
Print
$compilestatus
0 out of 5 stars
5 Stars | 0% | |
4 Stars | 0% | |
3 Stars | 0% | |
2 Stars | 0% | |
1 Stars | 0% |
Checks if an application program needs to be recompiled.
Syntax
$compilestatus(docname)
Parameters
docname | the name of an application document (not in quotation marks) |
Return Value
Number, with no decimal places.
Comments
$compilestatus checks, in order, a series of conditions in relation to docname. As soon as docname fails to meet a condition, $compilestatus returns the code number (1 through 8) associated with that condition. If docname meets all the conditions, $compilestatus returns a 0.
A $compilestatus expression can be compiled, but its value is fixed at compile time and does not change thereafter.
Code | Condition |
1 | The docname is not currently compiled. |
2 | The source file for docname is missing. |
3 | The compiled file for docname is missing. |
4 | The source file bears a date more recent than that of the compiled file. |
5 | No dependency information could be found for docname. |
6 | The dependency information predates the most recent compile and could therefore be out of date. |
7 | An object that docname depends on could not be found, it can be erased or located in an unaccessed directory. |
8 | An object that docname depends on has been modified since docname was last compiled. |
0 | No inconsistencies in the compilation status of docname were noted. |
Example
let status = $compilestatus(MyZIMProgram) case when status = 0 output "No need to compile" when status =2 output "No source file" when status = 7 output "Could not find a dependent object" otherwise compile MyZIMProgram endcase
Updated
ByJason Lee
Was this article helpful?
0 out of 5 stars
5 Stars | 0% | |
4 Stars | 0% | |
3 Stars | 0% | |
2 Stars | 0% | |
1 Stars | 0% |
5