Developer Discussions

Discuss topics with other Hexagon Geospatial Power Portfolio developers and experts to get the most out of our products.
Showing results for 
Search instead for 
Do you mean 
Regular Contributor
Posts: 253
Registered: ‎05-01-2016
Accepted Solution

Fancy Tooltips (Part 2)

[ Edited ]


$GP.queries.find  to find total number of queries...





Using the Fancy Tooltips example, if i add a filter so only states with temperature of 60 or higher will be selected and run example, the correct states have pins added. But then if i change the filter to "<" and "AVETEMP", 50, and run the example again, the same result is displayed. What code has to be changed to show the result of a subsequent query?  I am using the exact example except for adding a filter each time before running it again.  If i add the query to the legend, the correct points are displayed after each filter change but the pins never change although they erase before re-drawing.


featureClassId: "{}OM_USA_STATES",
url: "",
definitionName: "WFS",
queryName: queryName,
addToLegend: false,
filters: [{
operator: ">",
operands: ["AVETEMP", 60],


Regular Contributor
Posts: 253
Registered: ‎05-01-2016

Re: Fancy Tooltips (Part 2)

I see it is 


The [0] is the first query, 1 the second, etc.

What is the best way to get the latest query?

Technical Evangelist
Posts: 1,269
Registered: ‎09-11-2015

Re: Fancy Tooltips (Part 2)

Hi Jane,


Each time you use $GP.queries.add() you get a generated query object in the callback. So for me the best way would be to save the AnalysisID of this Query into some globally defined variable.



Jan Neumann
Post Sales Engineer Web Applications
Hexagon Geospatial