Desktop.html:
<!-- Customization -->
<script type="text/javascript" src="custom3.js"></script>
Custom3.js:
function dataSampleGauge2() {
var dataSampleGauge2 = new ej.circulargauge.CircularGauge({
// custom code start
load: function (args) {
args.gauge.height = (args.gauge.element.parentElement.parentElement.clientHeight - args.gauge.element.parentElement.children[0].clientHeight) + 'px';
},
// Other customization
});
var usa = new ej.circulargauge.CircularGauge(dataSampleGauge2, '#container2'); }
NewForm.cs:
IDL.FormatMessage((new IDVariant("<button id=\"click\" onclick=\"dataSampleGauge2()\">Click</button><div id=\"container2\" style=\"display: block;\"></div><script id=\"usa\" type=\"text/x-template\"> <div id='templateWrap'> <img src=\"//ej2.syncfusion.com/demos/src/circular-gauge/images/athletics.png\" style=\"height:20px; width:20px;\"/><div class='des'><div>${pointers[0].value}%</div></div></div></script>" +
"")), (new IDVariant(MyGlb.FRM_NEWFORM))).stringValue())
|
PAN_NEWPANEL.set_FieldText(PFL_NEWPANEL_USA, IDL.FormatMessage((new IDVariant("<button id=\"click\" onclick=\"dataSampleGauge2(20)\">Click</button><div id=\"container2\" style=\"display: block;\"></div><script id=\"usa\" type=\"text/x-template\"> <div id='templateWrap'> <img src=\"//ej2.syncfusion.com/demos/src/circular-gauge/images/athletics.png\" style=\"height:20px; width:20px;\"/><div class='des'><div>${pointers[0].value}%</div></div></div></script>" +
"")), (new IDVariant(MyGlb.FRM_NEWFORM))).stringValue());
Custom3.js:
function dataSampleGauge2(value) {
var dataSampleGauge2 = new ej.circulargauge.CircularGauge({
axes: [{
// other customizations
pointers: [{
value: value,
// other customizations
}]
}]
});
var usa = new ej.circulargauge.CircularGauge(dataSampleGauge2, '#container2');
} |