laptop and a wrench

Erro

IGraphicsContainerSelect::ElementSelectionCount property returns the count of all selected graphic elements in all layers.

Última Publicação: August 19, 2020 ArcGIS for Desktop
Número de ID do Erro NIM063236
EnviadoDecember 1, 2010
Última ModificaçãoFebruary 20, 2025
Aplica-se àArcGIS for Desktop
Versão encontrada10.0
Idioma do programaVBA
Sistema OperacionalWindows OS
Versão do Sistema Operacional7 64 Bit
StatusWill Not Be Addressed

Informações Adicionais

We apologize that we were unable to address this issue within the current product support cycle.  If the issue continues to affect your work in a supported release, please contact Technical Support.

Solução Provisória

Cast ActiveGraphicsLayer to IGraphicsContainer and loop through the elements to validate if they are selected or not.Sub SelectionCount() Dim pMxDocument As IMxDocument Set pMxDocument = ThisDocument Dim gc As IGraphicsContainer Set gc = pMxDocument.FocusMap.ActiveGraphicsLayer Dim pGraphicsContainerSelect As IGraphicsContainerSelect Set pGraphicsContainerSelect = gc gc.Reset Dim elem As IElement Set elem = gc.Next() Dim x As Integer x = 0 Do While Not elem Is Nothing If (pGraphicsContainerSelect.ElementSelected(elem) = True) Then x = x + 1 End If Set elem = gc.Next() Loop MsgBox pMxDocument.FocusMap.ActiveGraphicsLayer.Name & " is selected" & x & " elements" pMxDocument.ActiveView.RefreshEnd Sub

Etapas para Reproduzir

ID do Erro: NIM063236

Software:

  • ArcGIS for Desktop

Seja notificado quando o status de um erro mudar

Baixe o Aplicativo de Suporte da Esri

Descubra mais sobre este tema

Obtenha ajuda de especialistas do ArcGIS

Entre em contato com Suporte Técnico

Baixe o Aplicativo de Suporte da Esri

Ir para as opções de download