Method: MarkDataAsInvalid for ContextVnV <Data Preprocessor>
- Updated2024-09-12
- 1 minute(s) read
Methods > Method: MarkDataAsInvalid for ContextVnV <Data Preprocessor>
Method: MarkDataAsInvalid for ContextVnV <Data Preprocessor>
Marks the data to be processed as invalid.
Object.MarkDataAsInvalid(reason)
| Object | ContextVnV <Data Preprocessor> Object with this method |
| reason | String Contains the information why the data is invalid. |
The following example checks whether a channel exists, and marks the file as valid or invalid. If the file is valid, the example executes further analyses.
| VBScript | Python |
Sub On_ValidationAndVerification(oContext) If (Data.Root.ActiveChannelGroup.Channels(1).Name = "Time") Then Call oContext.MarkDataAsValid() Else Call oContext.MarkDataAsInvalid("Time channel does not exist") End If If oContext.IsDataValid Then ' do something End If End Sub