English

How To: Delete a thumbnail from an item's metadata.

Summary

It isn’t possible to delete an item’s thumbnail from the ArcCatalog user interface, however this can be accomplished using a simple VBA script.

Procedure

  1. Select the item in ArcCatalog whose thumbnail you want to delete.
  2. Open the Visual Basic Editor in ArcCatalog.

    In ArcCatalog, select Tools > Macros > Visual Basic Editor.

  3. Copy the VBA script below into a module.

    Code:
    Sub deleteThumbnail()
    Dim pGxApp As IGxApplication
    Dim pGxObj As IGxObject
    Dim pMD As IMetadata
    Dim pXPS As IXmlPropertySet

    Set pGxApp = Application
    Set pGxObj = pGxApp.SelectedObject
    Set pMD = pGxObj
    Set pXPS = pMD.Metadata

    pXPS.DeletePropertyByAttribute "EsriPropertyType", "Picture", True
    pMD.Metadata = pXPS
    End Sub

  4. Run the script.

    Note:
    If the thumbnail was created with ArcInfo 8.0.2, the thumbnail may reside within a Browse Graphic element that also contains a reference to an external graphic file that describes the dataset. To delete the thumbnail without deleting the other Browse Graphic information, change the Boolean parameter in the DeletePropertyByAttribute method from True to False.