# C1.C1Excel.XLPictureShape

## Content

<div class="doc-site-dotnet-api-container">



  <h1 id="C1_C1Excel_XLPictureShape" data-uid="C1.C1Excel.XLPictureShape" class="text-break">XLPictureShape Class
</h1>
  <div class="markdown level0 summary"><p>Represents an <a class="xref" href="C1.C1Excel.XLPictureShape.Image.html#C1_C1Excel_XLPictureShape_Image">Image</a> embedded in an <a class="xref" href="C1.C1Excel.XLSheet.html">XLSheet</a>.</p>
</div>
  <div class="markdown level0 conceptual"></div>
  <div class="inheritance">
    <h5>Inheritance</h5>
    <div class="level0"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object">object</a></div>
    <div class="level1"><a class="xref" href="C1.C1Excel.XLShape.html">XLShape</a></div>
    <div class="level2"><span class="xref">XLPictureShape</span></div>
  </div>
  <div class="implements">
    <h5>Implements</h5>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.icloneable">ICloneable</a></div>
  </div>
  <h6><strong>Namespace</strong>: <a class="xref" href="C1.C1Excel.html">C1.C1Excel</a></h6>
  <h6><strong>Assembly</strong>: C1.C1Excel.4.8.dll</h6>
  <h5 id="C1_C1Excel_XLPictureShape_syntax">Syntax</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public class XLPictureShape : XLShape, ICloneable</code></pre>
  </div>
  <div class="codewrapper">
    <pre><code class="lang-vbnet hljs">Public Class XLPictureShape
    Inherits XLShape
    Implements ICloneable</code></pre>
  </div>
  <h5 id="C1_C1Excel_XLPictureShape_remarks"><strong>Remarks</strong></h5>
  <div class="markdown level0 remarks"><p><b>XLPictureShape</b> derives from the generic <a class="xref" href="C1.C1Excel.XLShape.html">XLShape</a> class
to expose properties of images embedded in sheets. These properties include
the actual <a class="xref" href="C1.C1Excel.XLPictureShape.Image.html#C1_C1Excel_XLPictureShape_Image">Image</a> as well as information on how it should be
displayed, including <a class="xref" href="C1.C1Excel.XLPictureShape.Brightness.html#C1_C1Excel_XLPictureShape_Brightness">Brightness</a>, <a class="xref" href="C1.C1Excel.XLPictureShape.Contrast.html#C1_C1Excel_XLPictureShape_Contrast">Contrast</a>, and
clipping information.</p>
<p>You can add images to cells simply by assigning <a class="xref" href="C1.C1Excel.XLPictureShape.Image.html#C1_C1Excel_XLPictureShape_Image">Image</a> objects
directly to the <a class="xref" href="C1.C1Excel.XLCell.Value.html#C1_C1Excel_XLCell_Value">Value</a> property of <a class="xref" href="C1.C1Excel.XLCell.html">XLCell</a> objects. In 
this case, <a class="xref" href="C1.C1Excel.C1XLBook.html">C1XLBook</a> will create and initialize an <b>XLPictureShape</b>
automatically. However, this method does not provide a lot of flexibility in terms
of aligning, scaling, and clipping the image.</p>
<p>A more flexible option is to create an <b>XLPictureShape</b> object in code,
using the constructor that takes alignment and scaling parameters, and then
assign this <b>XLPictureShape</b> object to a cell's <a class="xref" href="C1.C1Excel.XLCell.Value.html#C1_C1Excel_XLCell_Value">Value</a>
property.</p>
</div>
  <h3 id="constructors">Constructors
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_C1Excel_XLPictureShape__ctor_C1_C1Excel_XLSheet_C1_Win_Bitmap_C1Bitmap_System_Int32_System_Int32_System_Int32_System_Int32_" data-uid="C1.C1Excel.XLPictureShape.#ctor(C1.C1Excel.XLSheet,C1.Win.Bitmap.C1Bitmap,System.Int32,System.Int32,System.Int32,System.Int32)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.-ctor.html#C1_C1Excel_XLPictureShape__ctor_C1_C1Excel_XLSheet_C1_Win_Bitmap_C1Bitmap_System_Int32_System_Int32_System_Int32_System_Int32_">XLPictureShape(XLSheet, C1Bitmap, int, int, int, int)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape__ctor_C1_C1Excel_XLSheet_System_Drawing_Image_System_Int32_System_Int32_System_Int32_System_Int32_" data-uid="C1.C1Excel.XLPictureShape.#ctor(C1.C1Excel.XLSheet,System.Drawing.Image,System.Int32,System.Int32,System.Int32,System.Int32)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.-ctor.html#C1_C1Excel_XLPictureShape__ctor_C1_C1Excel_XLSheet_System_Drawing_Image_System_Int32_System_Int32_System_Int32_System_Int32_">XLPictureShape(XLSheet, Image, int, int, int, int)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape__ctor_C1_Win_Bitmap_C1Bitmap_" data-uid="C1.C1Excel.XLPictureShape.#ctor(C1.Win.Bitmap.C1Bitmap)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.-ctor.html#C1_C1Excel_XLPictureShape__ctor_C1_Win_Bitmap_C1Bitmap_">XLPictureShape(C1Bitmap)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape__ctor_C1_Win_Bitmap_C1Bitmap_System_Drawing_RectangleF_" data-uid="C1.C1Excel.XLPictureShape.#ctor(C1.Win.Bitmap.C1Bitmap,System.Drawing.RectangleF)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.-ctor.html#C1_C1Excel_XLPictureShape__ctor_C1_Win_Bitmap_C1Bitmap_System_Drawing_RectangleF_">XLPictureShape(C1Bitmap, RectangleF)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape__ctor_C1_Win_Bitmap_C1Bitmap_System_Drawing_Size_System_Drawing_ContentAlignment_C1_C1Excel_ImageScaling_" data-uid="C1.C1Excel.XLPictureShape.#ctor(C1.Win.Bitmap.C1Bitmap,System.Drawing.Size,System.Drawing.ContentAlignment,C1.C1Excel.ImageScaling)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.-ctor.html#C1_C1Excel_XLPictureShape__ctor_C1_Win_Bitmap_C1Bitmap_System_Drawing_Size_System_Drawing_ContentAlignment_C1_C1Excel_ImageScaling_">XLPictureShape(C1Bitmap, Size, ContentAlignment, ImageScaling)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape__ctor_C1_Win_Bitmap_C1Bitmap_System_Int32_System_Int32_" data-uid="C1.C1Excel.XLPictureShape.#ctor(C1.Win.Bitmap.C1Bitmap,System.Int32,System.Int32)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.-ctor.html#C1_C1Excel_XLPictureShape__ctor_C1_Win_Bitmap_C1Bitmap_System_Int32_System_Int32_">XLPictureShape(C1Bitmap, int, int)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape__ctor_C1_Win_Bitmap_C1Bitmap_System_Int32_System_Int32_System_Int32_System_Int32_" data-uid="C1.C1Excel.XLPictureShape.#ctor(C1.Win.Bitmap.C1Bitmap,System.Int32,System.Int32,System.Int32,System.Int32)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.-ctor.html#C1_C1Excel_XLPictureShape__ctor_C1_Win_Bitmap_C1Bitmap_System_Int32_System_Int32_System_Int32_System_Int32_">XLPictureShape(C1Bitmap, int, int, int, int)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape__ctor_System_Drawing_Image_" data-uid="C1.C1Excel.XLPictureShape.#ctor(System.Drawing.Image)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.-ctor.html#C1_C1Excel_XLPictureShape__ctor_System_Drawing_Image_">XLPictureShape(Image)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape__ctor_System_Drawing_Image_System_Drawing_Rectangle_" data-uid="C1.C1Excel.XLPictureShape.#ctor(System.Drawing.Image,System.Drawing.Rectangle)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.-ctor.html#C1_C1Excel_XLPictureShape__ctor_System_Drawing_Image_System_Drawing_Rectangle_">XLPictureShape(Image, Rectangle)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape__ctor_System_Drawing_Image_System_Drawing_Size_System_Drawing_ContentAlignment_C1_C1Excel_ImageScaling_" data-uid="C1.C1Excel.XLPictureShape.#ctor(System.Drawing.Image,System.Drawing.Size,System.Drawing.ContentAlignment,C1.C1Excel.ImageScaling)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.-ctor.html#C1_C1Excel_XLPictureShape__ctor_System_Drawing_Image_System_Drawing_Size_System_Drawing_ContentAlignment_C1_C1Excel_ImageScaling_">XLPictureShape(Image, Size, ContentAlignment, ImageScaling)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape__ctor_System_Drawing_Image_System_Int32_System_Int32_" data-uid="C1.C1Excel.XLPictureShape.#ctor(System.Drawing.Image,System.Int32,System.Int32)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.-ctor.html#C1_C1Excel_XLPictureShape__ctor_System_Drawing_Image_System_Int32_System_Int32_">XLPictureShape(Image, int, int)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape__ctor_System_Drawing_Image_System_Int32_System_Int32_System_Int32_System_Int32_" data-uid="C1.C1Excel.XLPictureShape.#ctor(System.Drawing.Image,System.Int32,System.Int32,System.Int32,System.Int32)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.-ctor.html#C1_C1Excel_XLPictureShape__ctor_System_Drawing_Image_System_Int32_System_Int32_System_Int32_System_Int32_">XLPictureShape(Image, int, int, int, int)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="properties">Properties
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_BottomClip" data-uid="C1.C1Excel.XLPictureShape.BottomClip">
          <a class="xref" href="C1.C1Excel.XLPictureShape.BottomClip.html#C1_C1Excel_XLPictureShape_BottomClip">BottomClip</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the bottom clipping area of this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>, in twips.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_Brightness" data-uid="C1.C1Excel.XLPictureShape.Brightness">
          <a class="xref" href="C1.C1Excel.XLPictureShape.Brightness.html#C1_C1Excel_XLPictureShape_Brightness">Brightness</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the brightness of this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a> (between 0 and 1).</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_BrightnessInPercents" data-uid="C1.C1Excel.XLPictureShape.BrightnessInPercents">
          <a class="xref" href="C1.C1Excel.XLPictureShape.BrightnessInPercents.html#C1_C1Excel_XLPictureShape_BrightnessInPercents">BrightnessInPercents</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the brightness in percents of this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a> (between -100 and 100).</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_Contrast" data-uid="C1.C1Excel.XLPictureShape.Contrast">
          <a class="xref" href="C1.C1Excel.XLPictureShape.Contrast.html#C1_C1Excel_XLPictureShape_Contrast">Contrast</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the contrast of this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a> (between 0 and 1).</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_ContrastInPercents" data-uid="C1.C1Excel.XLPictureShape.ContrastInPercents">
          <a class="xref" href="C1.C1Excel.XLPictureShape.ContrastInPercents.html#C1_C1Excel_XLPictureShape_ContrastInPercents">ContrastInPercents</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the contrast in percents of this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a> (between -100 and 100).</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_FileName" data-uid="C1.C1Excel.XLPictureShape.FileName">
          <a class="xref" href="C1.C1Excel.XLPictureShape.FileName.html#C1_C1Excel_XLPictureShape_FileName">FileName</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the file name of this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_Image" data-uid="C1.C1Excel.XLPictureShape.Image">
          <a class="xref" href="C1.C1Excel.XLPictureShape.Image.html#C1_C1Excel_XLPictureShape_Image">Image</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a reference to the image/bitmap contained in this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_ImageSize" data-uid="C1.C1Excel.XLPictureShape.ImageSize">
          <a class="xref" href="C1.C1Excel.XLPictureShape.ImageSize.html#C1_C1Excel_XLPictureShape_ImageSize">ImageSize</a>
        </td>
        <td class="markdown level1 summary"><p>Gets image size in twips.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_IsEmpty" data-uid="C1.C1Excel.XLPictureShape.IsEmpty">
          <a class="xref" href="C1.C1Excel.XLPictureShape.IsEmpty.html#C1_C1Excel_XLPictureShape_IsEmpty">IsEmpty</a>
        </td>
        <td class="markdown level1 summary"><p>Determines whether the shape is empty.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_LeftClip" data-uid="C1.C1Excel.XLPictureShape.LeftClip">
          <a class="xref" href="C1.C1Excel.XLPictureShape.LeftClip.html#C1_C1Excel_XLPictureShape_LeftClip">LeftClip</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the left clipping area of this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>, in twips.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_Macro" data-uid="C1.C1Excel.XLPictureShape.Macro">
          <a class="xref" href="C1.C1Excel.XLPictureShape.Macro.html#C1_C1Excel_XLPictureShape_Macro">Macro</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the command of call macro of this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_RightClip" data-uid="C1.C1Excel.XLPictureShape.RightClip">
          <a class="xref" href="C1.C1Excel.XLPictureShape.RightClip.html#C1_C1Excel_XLPictureShape_RightClip">RightClip</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the right clipping area of this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>, in twips.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_TopClip" data-uid="C1.C1Excel.XLPictureShape.TopClip">
          <a class="xref" href="C1.C1Excel.XLPictureShape.TopClip.html#C1_C1Excel_XLPictureShape_TopClip">TopClip</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the top clipping area of this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>, in twips.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_Transparent" data-uid="C1.C1Excel.XLPictureShape.Transparent">
          <a class="xref" href="C1.C1Excel.XLPictureShape.Transparent.html#C1_C1Excel_XLPictureShape_Transparent">Transparent</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the transparent color of this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_ViewType" data-uid="C1.C1Excel.XLPictureShape.ViewType">
          <a class="xref" href="C1.C1Excel.XLPictureShape.ViewType.html#C1_C1Excel_XLPictureShape_ViewType">ViewType</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets whether this <a class="xref" href="C1.C1Excel.XLPictureShape.html">XLPictureShape</a> should be displayed in color, grayscale, or black and white.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="methods">Methods
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_CreateProperties_System_Collections_IDictionary_" data-uid="C1.C1Excel.XLPictureShape.CreateProperties(System.Collections.IDictionary)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.CreateProperties.html#C1_C1Excel_XLPictureShape_CreateProperties_System_Collections_IDictionary_">CreateProperties(IDictionary)</a>
        </td>
        <td class="markdown level1 summary"><p>Populates an <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.collections.idictionary">IDictionary</a> with the shape properties.</p>
</td>
      </tr>
      <tr>
        <td id="C1_C1Excel_XLPictureShape_ParseProperties_System_Collections_IDictionary_" data-uid="C1.C1Excel.XLPictureShape.ParseProperties(System.Collections.IDictionary)">
          <a class="xref" href="C1.C1Excel.XLPictureShape.ParseProperties.html#C1_C1Excel_XLPictureShape_ParseProperties_System_Collections_IDictionary_">ParseProperties(IDictionary)</a>
        </td>
        <td class="markdown level1 summary"><p>Parse shape properties.</p>
</td>
      </tr>
    </tbody>
  </table>

</div>
