|Microsoft DirectX 9.0|
The ReadXMLFile method loads an XML project file. This method creates instances of all the objects expressed in the XML file and inserts them into the timeline. The method also applies any attributes given for the timeline, such as frame rate or default effect.
object.ReadXMLFile( pTimeline As Unknown, XMLName As String )
The AMTimeline object that receives the timeline.
String that specifies the name of the file to load.
If the method fails, an error is raised, and Err.Number can be set to the following value:
|VFW_E_INVALID_FILE_FORMAT||Invalid file format.|
The pTimeline parameter appears in the Microsoft® Visual Basic® Object Browser as type Unknown. In fact, however, this parameter represents an AMTimeline object. The following code example shows how to call this method:
Dim objTimeline as New AMTimeline Dim objXmlParse as New Xml2Dex objXmlParse.ReadXMLFile objTimeline, "C:\XTL\Example.xtl"
This method does not clear existing objects from the timeline before it inserts the new objects defined in the XML file. If you need to refresh an existing timeline, call AMTimeline.ClearAllGroups first.