<< Click to Display Table of Contents >> LoadTemplate |
Loads a template file and creates a Template Object from it in memory.
The method returns a Template Object, which is the anchor object for the other template processing functions.
Using the VPE API, you can query the layout- and data source structure from a template. In addition you are able to perform several operations and modifications on a Template Object by code, including the assignment of values to fields (i.e. variables).
The template is logically linked to the specified VPE document and it will be removed automatically from memory when the VPE document is closed. Of course the template will be removed latest from memory when your application terminates.
method TVPETemplate VPE.LoadTemplate(
string FileName
)
string FileName
the path and file name of the file to load
Returns:
The Template Object, if the template file was found and could be loaded.
In case of an error an exception is thrown and LastError is set.
Remarks:
In case of an error, LastError is set accordingly to the status of the load process.
If the template has assigned an Authenticity Key, this method will fail.
Use LoadTemplateAuthKey() for loading templates with an Authenticity Key.
"dycodoc Template Processing" in the Programmer's Manual