Please see the code below, I have made use of the Cell.HtmlString property to achieve this result.
I have also attached the output file and the screenshot. The code is fully commented, so you will not have a trouble getting it.
//Create a workbook
Workbook workbook = new Workbook();
//Access its worksheet
Worksheet worksheet = workbook.Worksheets;
//Access cell A6
Cell cellA6 = worksheet.Cells[“A6”];
//Use HtmlString property to set the stylish text using html
//Save the workbook
And, if you want to use cells’ style/formatting to achieve your requirement, you may see the following topic:
Thank you very much.