Color code instead of actual color while printing


Hi @Vishal_Rajput,

It will show the code because In default print format hasn’t a feature to show the color in print format.

That for, use the custom print format and apply it like

<!DOCTYPE html>
<html>
<head>
  <title>Color Box</title>
  <style>
    #colorBox {
      width: 40px;
      height: 15px;
      background-color: {{doc.color}};
      border: 1px solid black;
    }
  </style>
</head>
<body>
    <div id="colorBox"></div>
</body>
</html>

We did set it on todo doctype and added it in custom print format.

Please set your color field name in HTML style.

background-color: {{doc.color}};

Output:

Thank You!

1 Like