Closed opu8232 closed 6 years ago
You have probably figured it out by now, e.g. if you searched old issues like #19. Anyway, here we go:
div
, span
or whatever you like and give that html element a decent id.setTextField
method.<body>
<canvas id="my_canvas"></canvas>
<span id="my_textfield"></span>
<script type="application/javascript">
var opts = {
// Deleted the contents of this. Use your own config.
};
var target = document.getElementById('my_canvas');
var gauge = new Gauge(target).setOptions(opts);
gauge.maxValue = 8000;
gauge.setMinValue(0);
gauge.animationSpeed = 32;
// Assign text field
var textField = document.getElementById("my_textfield");
gauge.setTextField(textField);
gauge.set(5000);
</script>
</body>
Please help me. what is the process to add current value?? I am new, please help me.