NotateXpress 13 for .NET - User Guide > How To > Annotate Programmatically > Create or Delete a Layer |
NotateXpress™ maintains annotations on layers. Layers act like transparent overlays to the image, and can be used to separate annotations. For example, a separate annotation layer could be established for each different end-user (e.g. legal department comments vs. marketing department comments on a proposal), or for each different function (e.g. plumbing notes vs. wiring notes on a house blueprint). Layers can be viewed simultaneously, or alone. (For example, view only legal department comment layer, or view legal department and marketing department comment layers).
Each NotateXpress object has an associated layer collection, accessed via the Layers property. Use the LayerCollection methods to add a new layer (Add), or insert a layer at a specified index (Insert). Alternatively, the application can copy existing layer(s) using the CopyTo, Paste, and Copy methods.
Make sure that NotateXpress has an associated valid ImagXpress ClientWindow prior to creating a layer. |
A layer (and its associated annotations) can be deleted, or removed, from the NotateXpress object's layer collection by calling the LayerCollection.Remove method. Calling LayerCollection.Clear removes all layers and their associated annotations from the collection.