Change the default file name when using Print PDF
Hi,
When I click Print PDF I get the the file downloaded with the name stuctured as follows:
[TABLENAME][ID]
Is it possible to chnage this so it uses a different name structure such as:
[TABLENAME][TEXTFIELD]
Hope someone can help.
9 replies
-
Hi,
you can create a button and print into pdf (file attachments) using following syntax:
importFile(this, printAndSaveRecord(this, "Layoutname"), "Filename.pdf")
Regards Emanuel
-
How can the same button code be altered to also open the attachment?
-
Cant thank you enough for that! Works a treat, I am going to add a selection so I can quickly choose a layout to print as there is a few available on each record but this is great, thanks again!! :)
-
Hi Westy,
this is not possible yet.
Emanuel
-
Hello!
This is a great solution to import that file directly to Ninox.
But what would be the code to save it on your PC rather then import in Ninox?
-
Hi Agassi,
You can only import and save it directly in the Ninox database with a code.
We have already planned to make it also possible to save attachments also on your device.
Thank you for your patience.
Greetings, Jörg
-
Jörg, thank you for the answer!
Actually, for me important is not to save the file on pc via code, but to save it with configurable name. Like now, by clicking the print button.
-
Agassi,
this is the syntax to achieve that:
importFile(this, printAndSaveRecord(this, "My Print Layout"), "mypdf.pdf")
or
importFile(this, printAndSaveRecord(this, "My Print Layout"), 'Own Name field'+".pdf")
The file will be saved in the attachement tab.
Steven.
-
Steven, thank you!
Because of my English I did not construct the frase correctly maybe.
I was looking for a way to save the file with a custom filename to local folder on my pc, not in Attachment tab in Ninox.
Anyway, thank you for your help! I guess what I want is not possible yet.
Content aside
- 5 yrs agoLast active
- 9Replies
- 3641Views