# Document Viewer

> Program the Document Viewer: architecture, loading and saving documents, navigation, annotations, form fields, signatures, the JavaScript API and events.

- **Product:** TX Text Control .NET Server
- **Section:** Documentation
- **Kind:** Topic
- **Path:** TX Text Control .NET Server > Document Viewer
- **902 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/llms-full.txt

---

Document portals, reviews, forms and e-signing are the kind of processes you build on the Document Viewer once it runs in your application. You learn how the viewer works at runtime, how your code loads documents and gets them back and how it controls annotations, form fields and signatures through the JavaScript API.

If you haven't added the viewer yet, start with [Getting Started: Document Viewer](https://docs.textcontrol.com/tx-text-control-dotnet-server/getting-started/document-viewer/llms-full.txt). The [Document Viewer](https://docs.textcontrol.com/tx-text-control-dotnet-server/overview/components/document-viewer/llms-full.txt) page in the Overview explains what the viewer is and how it differs from the Document Editor.

### How You Work With the Viewer

Users read, search, annotate, fill out and sign documents in the viewer, but they can't change the content. Your code works with the viewer in two places:

- **On the server,** your ASP.NET Core application passes documents to the viewer, renders their pages with the TX Text Control engine and receives what users submit, such as signed documents.
- **In the browser,** the JavaScript API, the `TXDocumentViewer` object, loads and saves documents and gives access to annotations, form fields, tracked changes, signatures and the user interface. Its events tell your code what users do.

The same JavaScript API works in the ASP.NET Core view, Angular, React and a plain JavaScript page. The examples of this section use the ASP.NET Core application of the Getting Started tutorial.

### Find the Right Page

| If you want to | Read |
|---|---|
| Understand the frontend, the controller of the backend, render modes and how to protect the endpoints | [Architecture](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/architecture/llms-full.txt) |
| Show documents from files, your database or your Web API | [Loading Documents](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/loading/llms-full.txt) |
| Get a document back with the values and annotations of the user, or download it as PDF | [Saving Documents](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/saving/llms-full.txt) |
| Scroll to pages, search the document or change the zoom | [Navigation](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/navigation/llms-full.txt), [Search](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/search/llms-full.txt), [Zooming](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/zooming/llms-full.txt) |
| Print documents | [Printing](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/printing/llms-full.txt) |
| Adapt the toolbar, the mobile view or the texts of the viewer | [User Interface](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/user-interface/llms-full.txt) |
| Let users comment on and mark documents, and store their annotations | [Annotations](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/annotations/llms-full.txt) |
| Let users review tracked changes | [Tracked Changes](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/tracked-changes/llms-full.txt) |
| Let users fill out forms and process the values | [Form Fields](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/form-fields/llms-full.txt) |
| Collect signatures and sign documents with certificates | [Digital Signatures](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/digital-signatures/llms-full.txt), [Signature Fields](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/signature-fields/llms-full.txt) |
| Learn when `TXDocumentViewer` is available and which methods return promises | [JavaScript API](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/javascript-api/llms-full.txt) |
| React to what users do in the viewer | [Events](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/events/llms-full.txt) |

### Where to Start

1. [Architecture](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/architecture/llms-full.txt): what happens between the browser and the server.
2. [JavaScript API](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/javascript-api/llms-full.txt): how your code talks to the viewer.
3. [Loading Documents](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/loading/llms-full.txt): get real documents into the viewer.
4. The page of the feature you need, from the table above.

### Related Sections

- [Document Editor](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-editor/llms-full.txt): create the documents, forms and signature fields that users view.
- [Digital Signatures](https://docs.textcontrol.com/tx-text-control-dotnet-server/digital-signatures/llms-full.txt): sign and validate PDF documents on the server.
- [PDF Processing](https://docs.textcontrol.com/tx-text-control-dotnet-server/pdf/llms-full.txt): create and process PDF documents and forms with `ServerTextControl`.

---

## In This Section

- [Annotations](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/annotations/llms-full.txt): Annotations in the Document Viewer: notes, text highlights, text, stamps and drawings, the annotation toolbar, custom stamps and the JSON format behind them.
- [Architecture](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/architecture/llms-full.txt): Run the Document Viewer in ASP.NET Core: the tx-document-viewer web component, TextControl controller, streamed pages, render modes, PDF.js and access tokens.
- [Digital Signatures](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/digital-signatures/llms-full.txt): Collect signatures in the Document Viewer with SignatureSettings, the signature dialog and the Signatures object, then sign SignatureData with a certificate.
- [Events](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/events/llms-full.txt): All events of the Document Viewer: documentViewerLoaded, documentLoaded, annotationsChanged, signaturesCompleted, link events, zoomChanged and form events.
- [Form Fields](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/form-fields/llms-full.txt): Let users fill out forms in the Document Viewer: supported form fields, the forms bar, validate and getValues, sending values to a controller and saving.
- [JavaScript API](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/javascript-api/llms-full.txt): Use the TXDocumentViewer JavaScript API in ASP.NET Core, Angular and React: documentViewerLoaded, promises of loadDocument and saveDocument and several viewers.
- [Loading Documents](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/loading/llms-full.txt): Load documents into the Document Viewer: DocumentPath and DocumentData in the view, loadDocument from JavaScript, load settings for comments and PDF.js.
- [Navigation](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/navigation/llms-full.txt): Navigate documents in the Document Viewer: scrolling, page thumbnails and the two-page view, scrollToPage and the events of document and hypertext links.
- [Printing](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/printing/llms-full.txt): Print from the Document Viewer: the Print and Download buttons, printDocument with the print function of the browser, downloadDocument and FormattingPrinter.
- [Saving Documents](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/saving/llms-full.txt): Save documents from the Document Viewer: saveDocument with form values and annotations, DocumentSaveResult, posting it to a controller and downloadDocument.
- [Search](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/search/llms-full.txt): Search documents in the Document Viewer: the search box of the toolbar and find, nextSearchResult and cancelSearch to search from your page with JavaScript.
- [Signature Fields](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/signature-fields/llms-full.txt): Turn signature fields into signature and initials boxes in the Document Viewer, activate the fields of each signer and check field names with ServerTextControl.
- [Tracked Changes](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/tracked-changes/llms-full.txt): Review tracked changes in the Document Viewer: the tracked changes toolbar, accepting and rejecting changes, showToolbar and reading decisions with getItems.
- [User Interface](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/user-interface/llms-full.txt): Adapt the Document Viewer's user interface: toolbar settings and methods, text selection, full screen, the mobile view and replacing the texts of the viewer.
- [Zooming](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/zooming/llms-full.txt): Zoom documents in the Document Viewer: the responsive default zoom, zoom and pan tools, lockZoom, the zoomChanged event and the render modes for sharp pages.

---

## Nearby

- **Previous:** [Events](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-editor/events/llms-full.txt)
- **Next:** [Architecture](https://docs.textcontrol.com/tx-text-control-dotnet-server/document-viewer/architecture/llms-full.txt)
