XMLNode.Validate Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Verifies an individual XML element or the entire document against the attached XML schema or schemas.
public:
void Validate();
public void Validate ();
abstract member Validate : unit -> unit
Public Sub Validate ()
Remarks
Use the Validate method with the ValidationStatus and ValidationErrorText[Boolean] properties to determine if an XML element is valid against the applied schema and what error text to display to the user. Use the SetValidationError(WdXMLValidationStatus, Object, Boolean) method to override the schema violations with custom validation errors.
When you run the Validate method, Microsoft Word populates the XMLSchemaViolations collection with the XML nodes that have validation errors.
Applies to
意見反應
https://aka.ms/ContentUserFeedback。
即將登場:在 2024 年,我們將逐步淘汰 GitHub 問題作為內容的意見反應機制,並將它取代為新的意見反應系統。 如需詳細資訊,請參閱:提交並檢視相關的意見反應