ArcGIS Pro 3.0 API Reference Guide
ArcGIS.Desktop.Framework Namespace / IPlugInWrapper Interface / LargeImage Property
Example

In This Topic
    LargeImage Property (IPlugInWrapper)
    In This Topic
    Gets or sets the image the plug-in should use in the user interface when it is in its large state (32x32).
    Syntax
    object LargeImage {get; set;}
    Property LargeImage As Object
    Example
    Change a buttons caption or image
    private void ChangeCaptionImage()
    {
      IPlugInWrapper wrapper = FrameworkApplication.GetPlugInWrapper("MyAddin_MyCustomButton");
      if (wrapper != null)
      {
        wrapper.Caption = "new caption";
    
        // ensure that T-Rex16 and T-Rex32 are included in your add-in under the images folder and have 
        // BuildAction = Resource and Copy to OutputDirectory = Do not copy
        wrapper.SmallImage = BuildImage("T-Rex16.png");
        wrapper.LargeImage = BuildImage("T-Rex32.png");
      }
    }
    
    private ImageSource BuildImage(string imageName)
    {
      return new BitmapImage(PackUriForResource(imageName));
    }
    
    private Uri PackUriForResource(string resourceName)
    {
      string asm = System.IO.Path.GetFileNameWithoutExtension(
          System.Reflection.Assembly.GetExecutingAssembly().Location);
      return new Uri(string.Format("pack://application:,,,/{0};component/Images/{1}", asm, resourceName), UriKind.Absolute);
    }
    
    Requirements

    Target Platforms: Windows 11, Windows 10, Windows 8.1

    See Also