PDF files
Last updated
Last updated
© 2024 UI Bakery
You might want to generate PDF files from your tables for reporting and other purposes. Here's how you can do it in UI Bakery:
In the Custom Code tab, specify the code below:
2. Load your data and add a table to display it. For example, we will load a table with users' data.
ion - Code. Specify the below code:
Please note the code is exemplary and needs to be changed based on your table's and necessary file's structure
4. As the next step, add a Button that will download the generated file.
5. Open the Button's settings, navigate Triggers section and assign the generatePDF action to the On Click trigger.
If you need to print the PDF files directly from UI Bakery, it can be achieved the following way:
Connect a JS library https://printjs.crabbly.com/#documentation in the Custom Code tab:
2. Add a Code action and specify a similar code:
where ui.pdfFileInput.value
is an input component with field type=file
.