I Have velocity template like this one :
+-----------------------------------------------------------+-------------+-------------+-------------+-------------+
| $totalPel Pelanggan | $totalBk | $totalAdm | $totalTag | $totalTotal |
+-----------------------------------------------------------+-------------+-------------+-------------+-------------+
When i put $totalPel -> 100, the result is :
+-----------------------------------------------------------+-------------+-------------+-------------+-------------+
| 100 Pelanggan | $totalBk | $totalAdm | $totalTag | $totalTotal |
+-----------------------------------------------------------+-------------+-------------+-------------+-------------+
Actually I want to get the result like this :
+-----------------------------------------------------------+-------------+-------------+-------------+-------------+
| 100 Pelanggan | $totalBk | $totalAdm | $totalTag | $totalTotal |
+-----------------------------------------------------------+-------------+-------------+-------------+-------------+
Anyone can show me how to make it?
I use this java code :
Velocity.init();
VelocityContext context = new VelocityContext();
context.put("totalPel", 100);
Template template = Velocity.getTemplate("LaporanTagihan.txt");
StringWriter writer = new StringWriter();
template.merge(context, writer);
System.out.println(writer.toString());