Skip to main content
Solved

HTML Report Generator Color object based on attribute


stefanh
Contributor
Forum|alt.badge.img+8

How can I give objects a color based on attribute value in an HTML-page generated with the HTML report generator. So I want an object to be 'red' when value is '1' and to be 'yellow' when the value is '2'.

I tried using the FeatureColorSetter, but this does not seem to work.

There is an ArcGIS Feature Layer available. I can add this to the Map (ESRI Leafet) option. However the colors are not visible in the map, because they are 'overlayed' by the layer color set in the HTML Report Generator

Is there a way to not set the layer color; this option is obliged. I do not know how to avoid this.

Best answer by annabelleatsafe

Hi @stefanh,

This is a feature we are currently working on supporting in future releases of FME. Currently there is no way to set the layer color based on an attribute, and this is being investigated as PR#74806. In regards to setting a layer to transparent, this is a second PR that I have filed on your behalf, PR#79757. We will follow up on this post when there is a fix or update to these PRs. My sincere apologies that you have run into this issue.

View original
Did this help you find an answer to your question?

4 replies

Forum|alt.badge.img+6

Hi @stefanh,

This is a feature we are currently working on supporting in future releases of FME. Currently there is no way to set the layer color based on an attribute, and this is being investigated as PR#74806. In regards to setting a layer to transparent, this is a second PR that I have filed on your behalf, PR#79757. We will follow up on this post when there is a fix or update to these PRs. My sincere apologies that you have run into this issue.


stefanh
Contributor
Forum|alt.badge.img+8
  • Author
  • Contributor
  • October 10, 2017
annabelleatsafe wrote:

Hi @stefanh,

This is a feature we are currently working on supporting in future releases of FME. Currently there is no way to set the layer color based on an attribute, and this is being investigated as PR#74806. In regards to setting a layer to transparent, this is a second PR that I have filed on your behalf, PR#79757. We will follow up on this post when there is a fix or update to these PRs. My sincere apologies that you have run into this issue.

Thanks for the reply and good to hear that you are working on the feature.

 

 

For now I used the 'Custom HTML' option in the HTML Report Generator. In the 'custom HTML' I created an HTML with an Leaflet viewer and the ArcGIS Feature Layer. This works perfect.

 


gio
Contributor
Forum|alt.badge.img+15
  • Contributor
  • October 10, 2017

@stefanh

Use an conditional attribute creator and set this to the relevant attributes.


stefanh
Contributor
Forum|alt.badge.img+8
  • Author
  • Contributor
  • October 11, 2017
gio wrote:

@stefanh

Use an conditional attribute creator and set this to the relevant attributes.

@gio

 

Thanks for the reply. However I was referring to a map, but it is good to know that it is working with a table.

 


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings