NotateXpress 13 for .NET - User Guide > How To > Retrieve Annotations > Retrieve Annotations from NX XML |
Annotations in a NotateXpress™ XML file or memory are loaded using the same methods as those used for loading .nxp annotation data from file or memory:
LoadOptions can be used, if desired, to provide specific instructions for loading the annotations.
Call the FromFile method to load the NotateXpress XML file into the NotateXpress layer collection. If the NotateXpress xml file is a multi-page file, set the PageNumber property to specify from which page annotations should be loaded. Attempting to load a page that does not exist will cause a PageNotFoundException.
LoadOptions can be used, if desired, to provide specific instructions for loading the annotations.
Annotations loaded from a NotateXpress XML file may be password protected by layer. When annotations are loaded from a file or variant, the LayerRestored event is raised. Additionally, if the layer was saved with a password, the RequestLayerPassword event is raised. This provides a trigger for the application to provide the password, or display a dialog to the end user requesting the password. If the correct password is supplied during the RequestLayerPassword event, the layer is decrypted and loaded into NotateXpress.