Hyperlink Class
Defines a hyperlink in the document.
Declaration
export class Hyperlink extends Field
Remarks
richEdit.selection.goToSubDocumentEnd();
richEdit.document.insertParagraph(richEdit.selection.active);
richEdit.document.hyperlinks.create(richEdit.selection.active+1, {text: "Visit our site", tooltip: "DevExpress site", url: "https://www.devexpress.com/"})
Inheritance
Field
Hyperlink
Properties
hyperlinkInfo Property
Provide access to information about a hyperlink.
Declaration
hyperlinkInfo: HyperlinkInfo
Property Value
Type | Description |
---|---|
HyperlinkInfo | An object that contain information about a hyperlink. |
Remarks
//Gets URLs of all hyperlinks in the main sub-document
var hyperlinks = richEdit.document.hyperlinks;
var hyperlinkUrls = [];
for(var i = 0, hyperlink; hyperlink = hyperlinks.getByIndex(i); i++)
if(hyperlink.hyperlinkInfo.url)
hyperlinkUrls.push(hyperlink.hyperlinkInfo.url);
See Also