Without the ability to add stacked bar charts in version 11, iSolutions decided to create a custom function that draws an HTML table header and displays only the header using a web viewer.
The custom function allows the user to choose the “100%” value, then each of the field (or an equation) for each of the numerical values that make up the 100 percent value. Each numerical value is then coupled with a hexadecimal color code for display.
The custom function is then referenced within the Web Viewer setup wherever the stacked bar is required for display. Using the web viewer provides the user with the flexibility to create any size bar and embed the bar into any tight spaces.
The custom function uses the “data url” prefix so that the HTML can be drawn without web publishing. Since the HTML is created using the calculation engine, it imposes minimal strain in the server, and can be used without hosting the database. Also, the chart can be viewed using FileMaker Go without alterations to the code.