WAB Custom Popup Widget

3698
1
Jump to solution
07-15-2016 02:08 PM
RenePretorius1
New Contributor

Good day,

I am still very new to developing custom WAB widget, so I would appreciate any help and guidance.

I was looking at the Popup Panel from Robert Scheitlin, GISP​, and it is a really great widget.

I was hoping I could get some help/suggestions on how to get a specific attribute's value for a selected feature? I want to use that value in a query to retrieve the image/s associated with the selected feature.

Thank for the help!

0 Kudos
1 Solution

Accepted Solutions
RobertScheitlin__GISP
MVP Emeritus

Rene,

  Add an event listener to the maps info window

map.infoWindow.on('set-features', function(){
   var gra = map.infoWindow.getSelectedFeature();
   console.info(gra.attributes.yourAttributeName);
});

View solution in original post

1 Reply
RobertScheitlin__GISP
MVP Emeritus

Rene,

  Add an event listener to the maps info window

map.infoWindow.on('set-features', function(){
   var gra = map.infoWindow.getSelectedFeature();
   console.info(gra.attributes.yourAttributeName);
});