Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
PersistentGlobalVariable is Null after using Interactive Sorting/Filtering
Reinhard_555
<p>I have modified a sample report from developer.actuate.com to demonstrate the following problem:</p>
<p><strong>I try to color data points in a line chart wich shows the "Profits by Product Line".</strong> If the profit margin is above 0.40, the marker is painted green, if it's below 0.38, it's painted red. The data that determines the color is stored in an ArrayList (PersistentGlobalVariable) in the beforeOpen/onFetch/beforeClose Event of the DataSet. The ArrayList is read in the OnRender event (beforeDrawDataPoint) and the fill color is set accordingly. This approach works fine until I enable iHub’s interactivity feature and try sorting or filtering a column in the table. <strong>After sorting or filtering, the PersistentGlobalVariable is null and therefore coloring the markers doesn't work anymore.</strong></p>
<p>I'm using the Trial Edition of iHub 16 and Analytics Designer 4.6.0.</p>
<p>I guess, this is a bug, because PersistentGlobalVariables shouldn't get null. PersistentGlobalVariables set in the Initilize Event don't get null after using interactive sorting/filtering.</p>
<p> </p>
<p>If this is a bug, is there a workaround?</p>
<p>If it’s not a bug, what's wrong with my approach?</p>
<p> </p>
<p>See the attached report file and the library file.</p>
Find more posts tagged with
Comments
micajblock
<p>No this is not a bug. When using Interactive Viewer, it regenerates the report without executing the data source. So I moved your code to the table and it works in IV as well now.</p>