XtremeDocumentStudio .NET
Next-generation multi-format document-processing component suite for .NET developers
Compatibility
Visual Studio 2010/2012/2013/2015

Getting Started with XtremeDocumentStudio .NET's Viewer Control

Display and print DOCX, PDF, BMP, PNG, JPG, WMF, EMF and (single-frame and multi-frame) TIFF files using C#.

We are happy to announce the release of XtremeDocumentStudio .NET, the next-generation multi-format document processing technology for .NET developers.

Introduction

Our goal with this product was to create a single toolset for enabling developers to perform every kind of document processing task, end-to-end, whether it be creating a document, editing, viewing, printing, converting or any other function that a business application needs to perform on a document, and be able to work with multiple document formats within the same toolset. So, now you have a single control to view and print Microsoft DOCX and PDF files.

Getting Started With XtremeDocumentStudio .NET

So, let us create a new C# project with XtremeDocumentStudio.

  1. Open Visual Studio.
  2. Create a new "Windows Forms" application.
  3. In the toolbox, add a new tab for XtremeDocumentStudio .NET.
  4. On this tab, add the Gnostice.Documents.Controls.WinForms.dll from the installation folder of XtremeDocumentStudio .NET. (This will add a new "DocumentViewer control to the tab.)
  5. Drag a DocumentViewer control on the form.
  6. Resize the form and the DocumentViewer control to your liking.
  7. Set the "Anchor" property of the DocumentViewer to "Bottom, Left, Right".
  8. Double-click the form and add the following handler for the "form load" event.
    // Activate the license
    Gnostice.Documents.Framework.ActivateLicense("your-license-key");
    
  9. Replace "your-license-key" with the key that you have received.
  10. Switch to Design view and add a button to the form.
  11. Double-click the form and add the following code for the "button click" event handler.
    // Load a document and display it
    documentViewer1.LoadDocument("sample_file.docx");
    
  12. Replace "sample_file.docx" in the LoadDocument() method with the pathname of a DOCX file in your computer. (The Demos folder in your "documents" folder contains a few sample files.)
  13. Press F5 to run the project.

Conclusion

In this article, you learned how to create a barebones viewer with XtremeDocumentStudio. You will find a more advanced viewer demo in the source code samples folder installed by the XtremeDocument .NET setup program. Please do check it out.

---o0O0o---

Our .NET Developer Tools
XtremeDocumentStudio .NET

Multi-format document-processing component suite for .NET developers.

PDFOne .NET

A .NET PDF component suite to create, edit, view, print, reorganize, encrypt, annotate, and bookmark PDF documents in .NET applications.

Our Delphi/C++Builder developer tools
XtremeDocumentStudio Delphi

Multi-format document-processing component suite for Delphi/C++Builder developers, covering both VCL and FireMonkey platforms.

eDocEngine VCL

A Delphi/C++Builder component suite for creating documents in over 20 formats and also export reports from popular Delphi reporting tools.

PDFtoolkit VCL

A Delphi/C++Builder component suite to edit, enhance, view, print, merge, split, encrypt, annotate, and bookmark PDF documents.

Our Java developer tools
XtremeDocumentStudio (for Java)

Multi-format document-processing component suite for Java developers.

PDFOne (for Java)

A Java PDF component suite to create, edit, view, print, reorganize, encrypt, annotate, bookmark PDF documents in Java applications.

Our Platform-Agnostic Cloud and On-Premises APIs
StarDocs

Cloud-hosted and On-Premises REST-based document-processing and document-viewing APIs

Privacy | Legal | Feedback | Newsletter | Blog | Resellers © 2002-2017 Gnostice Information Technologies Private Limited. All rights reserved.