Hit Test - Transparent Polygons

3287
3
10-13-2014 06:58 AM
JonDicken
New Contributor II

Hi,

I noticed today that some of our selection code (written using the 10.2.3 beta) was no longer working as expected for features on some of our layers. The issue occurred only on feature layers with transparent symbology defined when performing a hit test. This seemed strange, as it was working previously, so I headed over to look at the API, and found the below:

"When performing a hittest on a FeatureLayer with polygon based features, make sure that a non-transparent FillSymbol style is applied to the Renderer of the FeatureLayer. If no FillSymbol is applied, meaning the polygon fill is considered transparent (even though there may me a polygon outline symbol applied), the hittest will not return an RowID values."

Ah. This sounds like the problem. This was not the case in any of the beta releases of the runtime. Is there no way of performing a hit test on a transparent feature anymore (despite it having a solid border)?

I presume I must be missing something obvious?

Regards,

Jon

0 Kudos
3 Replies
MichaelBranscomb
Esri Frequent Contributor

Hi,

Unfortunately this is a limitation in the 10.2.4 release which we intend to address for the next release. The suggested workaround is to set the polygon fill style to “null” and the symbol color to something non-transparent.

Cheers

Mike

0 Kudos
JonDicken
New Contributor II

Hi,

Thanks for the prompt response, much appreciated. Is there any news on when the next release date may be?

Thanks,

Jon

0 Kudos
JenniferNery
Esri Regular Contributor

In addition to Mike's response, you may also use QueryAsync providing geometry in the SpatialFilter if working with ArcGISFeatureTable/ServiceFeatureTable or GeometryEngine.Intersects method.

0 Kudos