Insert image to excel cell using ClosedXml in ASP.Net

Last Reply 11 months ago By dharmendr

Posted 11 months ago

i have searched a lot. but i am unable to find exact code. please guide me to insert image to perticuler excel cell using closedxml 

Posted 11 months ago
Hi @suraj@123,
Please try the following

Insert Image in Excel using Interop Excel Library using C#

It might help you.

Cheers Andrea.

Posted 11 months ago

i have already tried this.


Posted 11 months ago


 xlWorkSheet.Shapes.AddPicture("C:\\csharp-xl-picture.JPG", Microsoft.Office.Core.MsoTriState.msoFalse, Microsoft.Office.Core.MsoTriState.msoCTrue, 50, 50, 300, 45); 

giving me error at " Microsoft.Office.Core.MsoTriState.msoFalse" as

MsoTriState is exist in both and office.

i have tried to remove office.dll but at the time of build it is recreating

Posted 11 months ago

You can't ask multiple queries within a question. This is against forum rules and necessary to maintain clean forum.
It is requested Mark Answer the replies when question is answered and ask a new question as a responsible member to help fellow programmers around the world.