Skip to main content
kavyam0002
Brainy
Apr 13, 2023 9:25 AM UTC
Question

link

i have to provide a link, once they click on that link the document has to be downloaded. for this i need to give 2 paramater 1. unituq id(we already have) 2. document id(we already have)

can anyone help me with this?

    2 replies

    amans0009
    Participating Frequently
    Apr 13, 2023 9:49 AM UTC

    You can also provide that document download link based on docId only   -> a!documentDownloadLink()

    {
      a!richTextDisplayField(
        labelPosition: "COLLAPSED",
        value: {
          a!richTextItem(
            text: "download doc",
            link: a!documentDownloadLink(document: 9116)
          )
        }
      )
    }

    mallepup3914
    Inspiring
    Apr 17, 2023 8:18 AM UTC

    Yes, as Eren suggested you can use the documentDownloadLink() in any linkfield or richTextDisplayField. You need to pass the doc id dynamically with id so when user clicks on it, then the doc will be downloaded to the system.