Sliver Polygon Renderer

Created:12/15/1999
Last Modified:12/15/2000
Description:

This sample renderer lets you display a common data automation error - sliver polygons. The sample code demonstrates how to create a custom renderer and an associated custom property page. Your renderer will only appear in the list of available feature renderers for polygon layers.

How to use:
  1. Register this sample's dll by compiling the sample or by using Regsvr32.exe.
  2. Using the Categories.exe program, add the SliverPropertyPage component from this sample's DLL to the 'ESRI Renderer Property Pages' category.
  3. Close and re-start ArcMap.
  4. Add a polygon feature class to your map and open the Layer Properties dialog. Go to the Symbology tab and select 'Automation' from the available renderer types.
  5. Specify a minimum area measurement and apply the renderer. To find the smallest and largest polygon in the layer, press the 'Calculate Area...' button.

Application:
ArcMap

Requires: A layer from a polygon feature class.

Difficulty: Advanced


Visual Basic
File Description
CustomRenderers.vbp Visual Basic project file for the renderer.
SliverRenderer.frm Form containing the controls and preview display for the renderer.
SliverPropertyPage.cls Class containing the code for the custom renderer property page.
ISliverPolygonRenderer.cls Interface class for the renderer.
SliverPolygonRenderer.cls Class containing the code for the custom renderer.


Key CoClasses: SimpleMarkerSymbol, SimpleFillSymbol, SymbolSelector
Key Interfaces: IComPropertyPage, IPropertyPageContext, IRendererPropertyPage, IFeatureRenderer, IPersistVariant, ISimpleMarkerSymbol, ISimpleFillSymbol, ISymbolSelector, IFeatureClass, IRGBColor, IFeatureDraw
Key Members: IComPropertyPage.Set, IComPropertyPage.Apply, IFeatureRenderer.Draw, ISymbolSelector.Select