DHTMLX Docs & Samples Explorer

setNumberFormat(name, format, groupSep, decSep)

Allows to set format of numeric data. Applied only to the input items.

Parameters:

  • name - the id of item (the item's parameter 'name')
  • format - the data format
  • groupSep - a mark that will be used to divide numbers with many digits into groups. By default - ”.” (dot)
  • decSep - a mark that will be used as the decimal delimiter. By default - ”,” (comma)
myForm.setNumberFormat("input5","$ 0,000.00","'",",");

Note, for specifying the format parameter you should use the default group and decimal separators (”.” and ”,”).