NativeExcel for .Net Developer's Reference

IHyperlinks Interface

Represents the collection of hyperlinks for a worksheet or range. Each hyperlink is represented by an IHyperlink interface.

For a list of all members of this type, see IHyperlinks Members.

[Visual Basic]
public__gc__interfaceIHyperlinks: publicIEnumerable


Use the IWorksheet.Hyperlinks property to return the IHyperlinks collection for the specified sheet.

Use the IRange.Hyperlinks property to return the IHyperlinks collection for the specified range.

The following example deletes the hyperlinks on worksheet one for a link that contains the word "Microsoft" in the TextToDisplay.

IWorksheet sheet = book.Worksheets[1];
if (sheet.Hyperlinks.Count > 0) {
    for (int i = sheet.Hyperlinks.Count; i > 0; i--) {
        if (sheet.Hyperlinks[i].TextToDisplay.IndexOf("Microsoft") >= 0)

Use the Add method to create a hyperlink and add it to the Hyperlinks collection. The following example creates a new hyperlink for cell A8.

IWorksheet sheet = book.Worksheets[1];
sheet.Hyperlinks.Add("A8", "");


Namespace: NativeExcel

Assembly: NativeExcel (in NativeExcel.dll)

See Also

IHyperlinks Members | NativeExcel Namespace | IWorksheet.Hyperlinks Property | IRange.Hyperlinks Property