Document Solutions for Word
DS.Documents.Word Assembly / GrapeCity.Documents.Word.Templates Namespace / DataTemplate Class / Validate Method
If true, erroneous tags will be marked in the document, and a GrapeCity.Documents.Word.Comment with the error description will be added to each such occurrence. If false, the templates will be left as is, just the list of errors will be returned.

In This Topic
    Validate Method
    In This Topic
    Validates all templates in the current document, finds any template tags that are malformed or used incorrectly.
    Syntax
    'Declaration
     
    Public Function Validate( _
       Optional ByVal markErrors As System.Boolean _
    ) As System.Collections.Generic.IEnumerable(Of TemplateError)
    public System.Collections.Generic.IEnumerable<TemplateError> Validate( 
       System.bool markErrors
    )

    Parameters

    markErrors
    If true, erroneous tags will be marked in the document, and a GrapeCity.Documents.Word.Comment with the error description will be added to each such occurrence. If false, the templates will be left as is, just the list of errors will be returned.

    Return Value

    The list of all found template errors.
    See Also