Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • putdocx table hyperlink from variable

    Hello Statalisters,

    I am puzzled about how to automatically reference a hyperlink from a var into a putdocx table.
    I do have titel, projectnumber and project URL. In the Word-Table I like to have the project number linking to the URL.

    Code:
    * Example generated by -dataex-. For more info, type help dataex
    clear
    input str19 name str13 geschäftszeichen1 str47 geprislink1
    "Test1"  "2048" "https://gepris.dfg.de/gepris/projekt/390686111"
    "Test2" "2004" "https://gepris.dfg.de/gepris/projekt/390534769"
    end
    label var name "Name"
    label var geschäftszeichen1 "Project no"
    label var geprislink1 "Link"
    
    putdocx clear
    putdocx begin, pagesize(A4) margin(top,2cm) margin(bottom, 2cm) margin(left,2cm) margin(right,2cm)
    putdocx paragraph,
    putdocx table test_1 = data(name geschäftszeichen1), varnames
    
    putdocx save test.docx
    Now I would like to include the link information from variable geprislink1 in the hyperlink info of geschäftszeichen1. Is there a good way to do this?
    Thank you very much.

Working...
X