martes, 12 de noviembre de 2024

Código SVG para imagenes vectoriales

 CÓDIGO SVG PARA APPSHEETS

El siguiente código lo puedes usar para realizar imagenes vectoriales en appsheets, la misma que representa una bileltera de imagen de ingresos y egresos.

CONCATENATE( "data:image/svg+xml;utf8,", substitute( ' <svg width="300" height="150" xmlns="http://www.w3.org/2000/svg"> <!-- Fondo y bordes --> <rect x="10" y="10" width="280" height="130" rx="10" fill="#f8f8f8" stroke="#ddd" stroke-width="2" /> <!-- Ingresos --> <text x="50" y="40" font-size="12" fill="#4caf50" text-anchor="middle">Ingresos</text> <rect x="30" y="50" width="40" height="60" fill="#4caf50" rx="5" id="barraIngresos" /> <text x="50" y="120" font-size="10" fill="#333" text-anchor="middle">$'&[Ingresos]&'</text> <!-- Egresos --> <text x="250" y="40" font-size="12" fill="#f44336" text-anchor="middle">Egresos</text> <rect x="230" y="50" width="40" height="40" fill="#f44336" rx="5" id="barraEgresos" /> <text x="250" y="120" font-size="10" fill="#333" text-anchor="middle">$'&[Egresos]&'</text> <!-- Balance neto --> <text x="150" y="80" font-size="14" fill="#333" text-anchor="middle">Saldo</text> <text x="150" y="100" font-size="16" fill="#333" text-anchor="middle">$'&[saldo]&'</text> <!-- Línea divisoria --> <line x1="150" y1="50" x2="150" y2="110" stroke="#ccc" stroke-width="1" stroke-dasharray="2,2" /> </svg> ', "#", "%23") )