Skip to content

Instantly share code, notes, and snippets.

@bjoerntx
Created March 20, 2023 16:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bjoerntx/c5374b1e53725e9f0a99ba28e02666da to your computer and use it in GitHub Desktop.
Save bjoerntx/c5374b1e53725e9f0a99ba28e02666da to your computer and use it in GitHub Desktop.
using TXTextControl.Web.MVC.DocumentViewer
<div style="width: 800px; height: 600px;">
@Html.TXTextControl().DocumentViewer(settings => {
settings.DocumentPath = "App_Data/test.pdf";
settings.Dock = DocumentViewerSettings.DockStyle.Fill;
settings.DocumentLoadSettings.PDFJS.BasePath = "https://cdnjs.cloudflare.com/ajax/libs/pdf.js/3.2.146";
}).Render()
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment