Document Tree Viewer with Atalasoft, Part Two

September 8, 2014 Kevin Hulse

In Part One of this series, I designed an API for a Document Tree Viewer now called WebDocumentRepository. Since then, I have completed its coding and created a working sample of it using our WebDocumentViewer and WebDocumentThumbnailer. The new control is easy to setup and configure:

_repo = new WebDocumentRepository(_viewer, _thumbs, $("#Tree"));

The constructor takes the WebDocumentViewer control, the WebDocumentThumbnailer, and the jQuery object where the tree view is to be placed. Once that has been called, the AddDocument method of the WebDocumentRepository is used to add each document:

_repo.AddDocument(doc.Path, doc.Name, doc.Url, doc.ToolTip);

Path – The folder structure to display in the Repository Viewer (e.g. “Documents/Educational”)
Name – The display name of the Document in the Repository Viewer
URL – The URL that the WebDocumentViewer will use to open the file
ToolTip – The display text of a mouse hover event on a document in the repository

Here is a live sample application I made using the WebDocumentRepository control:

Here are the resources I used to make this sample:

Use this sample as a starting point to add multiple document viewing functionality to your Atalasoft applications. If you have any questions, comments, or ideas as to how you are going to use this to improve your projects, please post them in the comments below.



About the Author

Kevin Hulse

Kevin is the Associate Solutions Enablement Specialist (a Technical Marketing position) at Atalasoft. He has worked prior in both engineering and support at Atalasoft. He also runs the company sponsored softball team and is an avid game player.

Follow on Twitter More Content by Kevin Hulse
Previous Article
PDF Forms: Appearances Can be Deceiving
PDF Forms: Appearances Can be Deceiving

This blog will cover some of the complexities that lurk behind...

Next Article
Hammers Vs. Nails
Hammers Vs. Nails

While working on our recent port of DotPdf to Java, I added a number of...

Try any of our Imaging SDKs free for 30 days with Full Support

Download Now