View Single Post
An HTML version of the link+label can be converted to RTF by Textutil, and then placed in the clipboard.

Code:
property pTitle : "Put labelled link in clipboard as RTF"
property pVer : "0.1"

set {strURL, strTitle} to {"", ""}

set strURL to text returned of (display dialog "Enter a URL:" default answer "http://" with title pTitle)
set strTitle to text returned of (display dialog "Enter a title for the link:" & linefeed & linefeed & strURL default answer "" with title pTitle)

if (strURL is not "") and (strTitle is not "") then
	set strHTML to quoted form of ("<font face=\"helvetica\"><a href=\"" & strURL & "\">" & strTitle & "</a></font>")
	do shell script "echo " & strHTML & "  | textutil -format html -convert rtf -inputencoding UTF-8 -stdin -stdout | pbcopy -Prefer rtf"
end if

display dialog "Lableled link in clipboard as RTF" buttons {"OK"} default button "OK" with title pTitle & "  ver. " & pVer
(Is is true, incidentally, that the .text property of a rich text field just returns a plain text string, but some reading/writing of text attributes is possible if you work with a reference rather than a direct coercion).