Question

I have an XSL file that I am generating from CSV from and Object etc. etc. Everything is done except that I need to highlight particular rows in the xsl file. I don't want to have to open Excel and use Macros.

Is there a way to do this in C#?

Was it helpful?

Solution

Do you mean XLS and not XSL?

If so, here's a link that explains the basics of how to use Excel as an object. Since you're opening it as an object, it won't be visible (unless you want it to be), but you'll have full access to navigate, highlight rows, and do whatever else you would normally do in Excel. When done, dispose the object.

Connecting to and navigating Excel through C#

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top