0

Default name for Printing to PDF

I'd like to have the name already specified when I go to Print a record.

Ideally it would be Kelly_Invoice70299, and the number comes from the field "InvNumber".

Right now when I go to print it defaults to just the Table name and Record ID. Not sure where to specify that.

4 replies

null
    • james_deraps
    • 4 yrs ago
    • Reported - view

    Use the + sign (when printing a report) and use formula like that {Name+"_invoice" + InvNumber} 

    for Kelly_invoice70299

    • Kelly
    • 4 yrs ago
    • Reported - view

    Right now my button has  printRecord(this, "_invoice")

    But it still spits it out ignoring the _invoice part.

     

    When i do just printRecord(Name+"_invoice") 

    I get Function is not defined: printRecord(string)

    • Choices_Software_Dean
    • 4 yrs ago
    • Reported - view

    "_invoice" is the name of the layout that is being printed, not the file name of the resulting pdf file.

    • Choices_Software_Dean
    • 4 yrs ago
    • Reported - view

    Try this. First make sure "File Attachments" is checked under the table properties. Then go back to the data entry form and place a button with the following:

    importFile(this, printAndSaveRecord(this, "layoutname"), "formname.pdf")

    Replace layoutname and formname with your layout name and form name. Click the button. Look under the Attachment tab and the newly created pdf file will be shown as an attachment. Now you just need a script that will automatically open that attachment. Maybe someone else can help with that. I do not know how to do that piece.

Content aside

  • 4 yrs agoLast active
  • 4Replies
  • 1739Views