//create a new workbook var workbook = new GrapeCity.Documents.Excel.Workbook(); IWorksheet worksheet = workbook.Worksheets[0]; HyperLinkCellType cellType = new HyperLinkCellType { Text = "Google", LinkColor = "Blue", LinkToolTip = "Search by google", VisitedLinkColor = "Green", Target = HyperLinkTargetType.Blank }; worksheet.Range["C5"].CellType = cellType; worksheet.Range["C5"].Value = "https://www.google.com"; // Save to a pdf file workbook.Save("AddHyperlinkCellType.pdf");
' Create a new Workbook Dim workbook As New Workbook Dim worksheet As IWorksheet = workbook.Worksheets(0) Dim cellType As New HyperLinkCellType With { .Text = "Goole", .LinkColor = "Blue", .LinkToolTip = "Search by google", .VisitedLinkColor = "Green", .Target = HyperLinkTargetType.Blank } With worksheet.Range!C5 .CellType = cellType .Value = "https://www.google.com" End With ' save to a pdf file workbook.Save("AddHyperlinkCellType.pdf")