Frameworks
Integrations
Mendix
SharePoint
Default UI
Modular UI
AnnotationManager
Annotation Types
Customize
Version 11
Version 10
v10.12
v10.11
v10.10
v10.9
v10.8
v10.7
v10.6
v10.5
v10.4
v10.3
v10.2
v10.1
v10.0
Version 8
v8.12
v8.11
v8.10
v8.9
v8.8
v8.7
v8.6
v8.5
v8.4
v8.3
v8.2
v8.1
v8.0
Version 7
Version 6
v6.3
v6.2
v6.1
v6.0
Version 5
Version 4
Version 3
Version 2
WebViewer Server
WebViewer BIM
By now, you should have setup WebViewer and read all about the DocumentViewer, but a very common use case is interacting with annotations.
The main way to access and work with annotations is through the AnnotationManager
. Like with the DocumentViewer when using the WebViewer UI, this is also available through the Core
namespace and is one of the main objects you will likely interact with.
Fetching a list of annotations in the document can be done via the AnnotationManager. This is done through the getAnnotationsList
API. This list is the complete list so it will include link annotations and widgets (form controls).
If you know the ID of your annotation, you can use getAnnotationById
to get it.
If you are working with user interactions and would like to get the annotations under the cursor at some point, the AnnotationManager provides two methods that will help depending on what you want to do:
Adding new annotations is also done through the AnnotationManager with the addAnnotation
or addAnnotations
API. Be sure to check out how to create annotations in our other guide.
When adding annotations or changing their properties directly, always call redrawAnnotation to rerender the annotation.
Like with adding annotations, the AnnotationManager provides the deleteAnnotation
and deleteAnnotations
APIs to delete annotations. You must have a reference to the annotation to use these methods.
Now that you know how to add annotations, learn how to create them!
Did you find this helpful?
Trial setup questions?
Ask experts on DiscordNeed other help?
Contact SupportPricing or product questions?
Contact Sales