JVCL Help:TJvTranslator.ComponentToXML

From Project JEDI Wiki
Jump to navigationJump to search
JEDI Visual Component Library Help

Search in JVCL Help

 
Search in all projects
 

Summary

Converts the properties of a TComponent to an XML string.


Pascal

 functionComponentToXML(constAComponent: TComponent; Recurse: Boolean): string;


Parameters

Parameters Description
const AComponent: TComponent The component to create the XML fragment for. If AComponent is found in the skip list, its properties will not be listed. If any of the component's properties is found in the skip list, the property will not be listed. If AComponent is Application, a root node with the name 'Translation' is automatically added to the returned XML.
Recurse: Boolean Set this parameter to true to recurse the Components array of AComponent and create the XML for owned components as well. If AComponent is in the skip list and Recurse is true, the owned components of AComponent will still be checked and its properties added to the XML string.


Return Value

An XML string then can be used in calls to TJvTranslator.Translate or as a building block for an XML translation template file.


Description

Use ComponentToXML to convert the name and published properties of a TComponent instance into a correctly formatted XML string compatible with the format used by JvTranslator. You can create a complete translation template file for your application by calling ComponentToXML for the Application object.
Note that ComponentToXML lists all published properties not skipped by a call to SkipProperty of a component and you might have to clean the returned XML from properties you don't need to translate.


See Also

TJvTranslator.SkipClass, TJvTranslator.SkipProperty, TJvTranslator.InSkipList


About

Contribute to this help topic

This documentation wiki is based on the collaborative effort of Project JEDI users. Your edits are welcome in order to improve documentation quality: edit this page