Why isn't the highlight method working in a 2d layer view?

1638
4
Jump to solution
03-19-2018 01:35 PM
JackFairfield
Occasional Contributor II

I am trying to simply highlight a graphic from a feature layer using the highlight method on the feature layer view (Highlight).

I changed the basic feature layer example by adding this section:

view.whenLayerView(featureLayer).then(function (lyrView) {
 lyrView.highlight(1148);
});

Here is a live example:

Live Example

I did notice this caveat in the documentation, but I am setting the webgl property in the dojo config:

Known Limitations

In 2D MapViews this method is only supported for FeatureLayers that have opted in to WebGL rendering.

I'm not sure if there is something I'm doing wrong, or if it's a bug in the js sdk.  Any help would be appreciated.

0 Kudos
1 Solution

Accepted Solutions
RobertScheitlin__GISP
MVP Emeritus

Jack,

   The support for webGL rendering is currently only available when using a AGOL hosted feature service. When 10.6.1 ArcGIS Server comes out you will be able to use webGL with your map services.

View solution in original post

4 Replies
JackFairfield
Occasional Contributor II

Does anyone have any ideas?  I still haven't figured it out.  Seems like it should be straightforward.

0 Kudos
RobertScheitlin__GISP
MVP Emeritus

Jack,

   The support for webGL rendering is currently only available when using a AGOL hosted feature service. When 10.6.1 ArcGIS Server comes out you will be able to use webGL with your map services.

avmesquita
New Contributor

Ok. I understand.

It seems weird.

But, if I use a Popup with attributes, without hosted feature service, hightlight does work automaticaly.

Why?

0 Kudos
RobertScheitlin__GISP
MVP Emeritus

@avmesquita  This post is 3 years old and no longer applies to the current JS API.

0 Kudos