HTML Presentation Object: Show Measure Values
Jump to navigation
Jump to search
This is an example is a simple customized presentation object which shows a value from a context variable measureValue. If the context variable value is changed, the new value is updated to the HTML presentation object.
<div id="content_<#uniqueId>"><div>
<style>
#content_<#uniqueId> {
font-size: 20px;
font-weight: bold;
}
</style>
<script>
function <#contextChangeFunction>(changedContextVariables) {
if (changedContextVariables["measureValue"] != null) {
$("#content_<#uniqueId>").text(changedContextVariables["measureValue"]);
}
}
function <#resizeFunction>(newWidth, newHeight) {
if (newWidth < 100) {
$("#content_<#uniqueId>").css("margin-left", "0px");
} else {
$("#content_<#uniqueId>").css("margin-left", "20px");
}
}
</script>