React Spreadsheet Hyperlinks

    The React Spreadsheet component allows display of pre-existing hyperlinks in your Excel workbook as well as insertion of new ones that can link to websites, file directories, and even other worksheets in the workbook.

    EXAMPLE
    DATA
    TSX

    Like this sample? Get access to our complete Ignite UI for React toolkit and start building your own apps in minutes. Download it for free.

    Hyperlinks are added to the IgrSpreadsheet control by accessing the Hyperlinks collection on the worksheet that you want to place the hyperlink on. This collection has an Add method that takes a WorksheetHyperlink object, where you can define the cell address, the hyperlink URL to be navigated to, the display text, and a tooltip to optionally be displayed on hover.

    Ignite UI for React | CTA Banner

    Dependencies

    When setting up your React spreadsheet control to use hyperlinks, you will need to import the WorksheetHyperlink class like so:

    import { WorksheetHyperlink } from 'igniteui-react-excel';
    ts

    Code Snippet

    The following code snippet demonstrates how to add a hyperlink to the currently viewed worksheet in the React IgrSpreadsheet control:

    this.spreadsheet.activeWorksheet.hyperlinks().add(new WorksheetHyperlink("A1", "http://ko.infragistics.com", "Infragistics", "Infragistics Home Page"));
    ts

    API References