i want to create health flag , i create one field on that if i insert 0-5 show different colour flag ,5-10 different colour flag like that how it is possible ,
i used this code
<!DOCTYPE html>
<html>
<body>
<script>
function myFunction() {
var value1 = window.parent.Xrm.Page.getAttribute("new_health").getValue();
if (value1 < 5) {
<p><font color="yellow" size="20"> ⚑</font></p>
}
else if (value1 == 5 || value1 < 10) {
<p><font color="blue" size="20"> ⚑</font></p>
}
else if (value1 == 10 || value1 < 15) {
<p><font color="purple" size="20"> ⚑</font></p>
}
else if (value1 == 15 || value1 <= 20) {
<p><font color="red" size="20"> ⚑</font></p>
}
else {
<p><font color="green" size="20"> ⚑</font></p>
}
}
</script>
</body>
</html>