Hi all.
Is there any way to generate bookmark and header for all pdf page from html file?
Gia Nguyen Le
@Gia Nguyen Le
Posts made by Gia Nguyen Le
-
Generate Bookmark and header
-
Is there anyway to generate water mark for all pdf page?
Hi all
Is there anyway to generate water mark for all pdf page?Thank you
-
Is there any example to generate pdf password?
I try to create a password for my pdf. The pdf generate succeed but with thout pass word.
Here is my code:var template = new Template()
{
Recipe = recipe,
Engine = engine,
Chrome = new Chrome
{
MarginTop = templateConfig.Chrome.MarginTop,
MarginLeft = templateConfig.Chrome.MarginLeft,
MarginRight = templateConfig.Chrome.MarginRight,
MarginBottom = templateConfig.Chrome.MarginBottom,
FooterTemplate = templateConfig.Chrome.FooterTemplate,
Format = templateConfig.Chrome.Format,
Landscape = templateConfig.Chrome.Landscape
},
PdfPassword = new PdfPassword
{
Password = "@123"
},};
var report = await _localReporting.RenderAsync(new RenderRequest()
{
Template = template});
Startup Class:
services.AddJsReport(new LocalReporting().UseBinary(RuntimeInformation.IsOSPlatform(OSPlatform.Windows) ? JsReportBinary.GetBinary() : jsreport.Binary.Linux.JsReportBinary.GetBinary()) .Configure(cfg => { cfg.AllowedLocalFilesAccess().FileSystemStore().BaseUrlAsWorkingDirectory(); cfg.Discover = true; return cfg; }) .AsUtility() .Create());
-
RE: How to configure extension options in middleware?
Hi @jan_blaha
I alreadt install latest jsreport.Types nuget
My tepmlate is
var template = new Template()
{
Recipe = recipe,
Engine = engine,
Chrome = new Chrome
{
MarginTop = templateConfig.Chrome.MarginTop,
MarginLeft = templateConfig.Chrome.MarginLeft,
MarginRight = templateConfig.Chrome.MarginRight,
MarginBottom = templateConfig.Chrome.MarginBottom,
FooterTemplate = templateConfig.Chrome.FooterTemplate,
Format = templateConfig.Chrome.Format,
Landscape = templateConfig.Chrome.Landscape
},
PdfPassword = new PdfPassword
{
Password = "@123"
},};
and generate pdf here
var report = await _localReporting.RenderAsync(new RenderRequest()
{
Template = template});
The pdf is generate succeed but When I open it doesn't require password.
Please help me take a look on thisThank you