Reputation: 6319
I am trying to include the spreadsheet's own filename in an e-mail body dynamically created with the following formula including a VBA Module (?) function:
=HYPERLINK("mailto:"&"address"&"?subject="&B7&"&body="&B7&FullName(); "E-Mail")
The function is
Function FullName() As String
FullName = ThisWorkbook.FullName()
End Function
in a "module" of the document (I don't have a clue about VBA: ALT+F11, Insert Module. Apparently this is also called user defined function (UDF)).
The function works on its own in a cell, the HYPERLINK formula works without adding to its link_location the function, but together (as above), it evaluates to
#NAME?
Links:
Upvotes: 0
Views: 638
Reputation: 6319
Follow this answer from the latter link in the question (do not use HYPERLINK formula, instead a function changes the manually created link in the cell).
Upvotes: 0