laptop and a wrench

Bug

A graphics layer (Added through ArcObjects ICompositeGraphicsLayer) does not properly reproject on the fly.

Zuletzt veröffentlicht: August 25, 2014 No Product Found
Bug-ID-Nummer NIM002790
EingereichtJune 1, 2006
Zuletzt geändertJune 5, 2024
Gilt fürNo Product Found
Gefunden in Version9.1
StatusNon-Reproducible

Zusätzliche Informationen

No Public Explanation

Workaround

This code will add a layer to your map document that is connected to a newly created annotation group and then add a point the annotation group. When you turn the layer on and off the annotation group turns on and off. =================Public Sub CreateAnnoGroupGraphLayer()Dim pMxDoc As IMxDocumentDim pMap As IMapDim pGraLyr As ICompositeGraphicsLayerDim pEnumElement As IEnumElementDim pNewAnnoGroup As IGraphicsLayerDim pNewGraCont As IGraphicsContainerDim pElement As IElementSet pMxDoc = ThisDocumentSet pMap = pMxDoc.FocusMapSet pGraLyr = pMap.BasicGraphicsLayerSet pNewGraCont = pGraLyr'Create a graphics layerDim pLayer As ILayerSet pLayer = pGraLyr'Create the new graphics layer group and add the graphics layer to the map.Set pNewAnnoGroup = pGraLyr.AddLayer("New Anno", Nothing)Set pNewGraCont = pNewAnnoGrouppMap.AddLayer pNewGraCont'Make a pointDim pPnt As IPointSet pPnt = New PointpPnt.X = 32pPnt.Y = 35 'Set color and symbol for the pointDim pColor As IRgbColorSet pColor = New RgbColorpColor.Blue = 255pColor.Green = 0pColor.Red = 0Dim pSimpleMarkerSymbol As ISimpleMarkerSymbolSet pSimpleMarkerSymbol = New SimpleMarkerSymbolWith pSimpleMarkerSymbol .Style = esriSMSCircle .size = 8 .Color = pColorEnd With 'Create a marker elementDim pMarkerElement As IMarkerElementSet pMarkerElement = New MarkerElementpMarkerElement.Symbol = pSimpleMarkerSymbolSet pElement = pMarkerElementpElement.Geometry = pPnt 'Add the marker element ot the layer graphics containerSet pNewGraCont = pNewGraContpNewGraCont.AddElement pMarkerElement, 0 'Refresh/redraw the display with the new pointpMxDoc.ActiveView.RefreshEnd Sub

Schritte zur Reproduzierung

Bug-ID: NIM002790

Software:

  • No Product Found

Benachrichtigung erhalten, wenn sich der Status eines Bugs ändert

Esri Support App herunterladen

Weitere Informationen zu diesem Thema erkunden

Unterstützung durch ArcGIS-Experten anfordern

An den technischen Support wenden

Esri Support App herunterladen

Zu Download-Optionen wechseln