AnsweredAssumed Answered

Calling a function from another widget

Question asked by natevatt on Jan 13, 2015
Latest reply on Jul 24, 2018 by rscheitlin

Hello,

 

Does anyone know how to call a function from a seperate widget?  I have created a simple search tool, which will run a query, and return graphic results on the map.  But I also want these results to display in a different custom table app.  I can pass the results to the infowindow features: this.map.infoWindow.setFeatures(features);  which is fine, but I have no way telling the table app to now display the results.

 

The best way I can think of is using some arbitrary map event listener (see here).  Something like 'update-end' and have that listener registered in my table app.  But obviously, the best way would be to simply call the function.

 

There are also the publishData and fetchData methods which are very briefly described here 'Communitcation between widgets', but I am not sure how I am supposed to use them.

 

Anyone had this issue before?

 

thanks,

Nat

Outcomes