setFormat method

Future<void> setFormat(
  1. dynamic format,
  2. String measureName
)

Sets a default number format or the number format for the specified measure. Use refresh() API call after setting a format to redraw the component and see changes.

Implementation

Future<void> setFormat(dynamic format, String measureName) async {
  WebViewController apiController = await controller.future;
  await apiController.runJavascript(
      '''webdatarocks.setFormat(${jsonEncode(format)},'$measureName'})''');
}