How to create a link inside a cell using EPPlus

后端 未结 6 639
醉酒成梦
醉酒成梦 2021-02-01 12:40

I am trying to figure out how to write a Hyperlink inside a cell using EPPlus instead of the cell containing the link text. I need it to be recognized as a link and be clickable

6条回答
  •  醉梦人生
    2021-02-01 13:36

    The below code worked fine with me.

    string FileRootPath = "http://www.google.com";
    _Worksheet.Cells[intCellNumber, 1].Formula = "HYPERLINK(\"" + FileRootPath + "\",\"" + DisplayText + "\")";
    

    I hope this would help you.

    Happy coding!!

提交回复
热议问题