Validate.SK is a SheetKraft function used to validate a condition and report custom message.
In numerous cases we need to validate certain condition and display warning/error message, validate.SK function is useful in such cases.
|Condition||The condition to be validated must be entered.|
|Message||The message that will be reported if the condition is not TRUE.|
|Code||Code is the nature of validation.
0 for information.(default)
-1000 to -1 for errors(Process will not execute successfully)
1 to 1000 for warnings(Process will execute displaying warning )
|Function||The custom function to which the validation belongs.(Optional)|
Let us consider example:
We will run the process on excel add-in and Web using correct files and incorrect files to check validate.SK. We will consider two cases:
Upload same dated files(both the Mapping File and Exchange Rate File are of date 27-03-2019)
Upload different dated files(the Mapping File is of date 27-03-2019 and Exchange Rate File is of date
Remark: Fail. Error msg- 'kindly provide correct dated files'. The Validate.SK checks the condition and as the condition is dissatisfied the error msg is displayed.
The videos of the example are provided below:-