-1

Can we add tooltip on each and every cell in a particular Excel sheet in .NET code with Spire.xls?

I have googled but didn't get correct answer, though below solution didn't work for me.

Is there a way to add tooltip to excel cell data in c#

Could anyone please help me here?

The code should be written in C# and running on .NET.

1

1 Answer 1

0

You can add comments to Excel cells. Checking the following code example:

using Spire.Xls;

namespace Comment
{
    class Program
    {
        static void Main(string[] args)
        {
            //Create a Workbook object
            Workbook workbook = new Workbook();

            //Load the sample workbook
            workbook.LoadFromFile("Sample.xlsx");

            //Get the first worksheet
            Worksheet sheet = workbook.Worksheets[0];

            //Add regular comment to specific cell range C6
            CellRange range = sheet.Range["C6"];
            ExcelComment comment = range.AddComment();
            comment.Text = "Regular comment";                      
            
            //Save the Excel workbook.
            workbook.SaveToFile("Addcomment.xlsx", ExcelVersion.Version2016);
        }
    }
}

https://www.e-iceblue.com/Tutorials/Spire.XLS/Spire.XLS-Program-Guide/Add-Comments-in-Excel-and-Set-Comments-Format-with-C-VB.NET.html

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.