C#: Online Guide
How To: excel SDK
Insert Image
Home ›› XDoc.Excel ›› C# Excel: Insert Image

C# Excel - Insert Image to Excel File Page in C#.NET

Insert Image to Excel Document Page in C# Project

Related .net document control helps:
asp.net excel file viewer: ASP.NET Excel Document Viewer in C# Control: view office excel files online in ASP.NET web applications
asp.net pdf viewer control: ASP.NET PDF Viewer Control: view, navigate, zoom Adobe PDF document in C# ASP.NET
asp.net pdf file viewer: ASP.NET PDF Document Viewer in C#: view, annotate, redact Adobe PDF files online in ASP.NET
asp.net webforms file viewer: ASP.NET WebForms application document viewer control: view, annotate, redact, convert files online in ASP.NET
file redact asp.net: Redact document ASP.NET: add, delete, apply redaction on PDF files in web browser using C#.net
view document asp.net: View multiple document formats in ASP.NET, MVC, Ajax, Azure using C# control
asp.net office document viewer: ASP.NET Office Word Document Viewer: view MS Office Word files online using C# in ASP.NET web applications


RasterEdge XDoc.Excel Library provides some methods for developers to insert image to Excel file pages. While, if you want to insert various type image, you may need add the reference RasterEdge.XImage.Raster.dll into your project. If not, you can only add bitmap to the  Excel document page(s).

Add Image to Excel File Page Using C#

Add necessary references:











Using namespace:

  using RasterEdge.Imaging.Basic;

  using RasterEdge.XDoc.Excel;

  using RasterEdge.Imaging.Raster.Core;

Add image to Excel file page using C#.

XLSXDocument doc = new XLSXDocument(@"C:\1.xlsx");
BasePage page = doc.GetPage(0);
REImage image = new REImage(@"C:\logo2.jpg");
page.AddImage(image, new Point(100, 100));