I have a colorpicker as part of a form I am loading via json, but wanted to have the customColors enabled. How would I do that? I have tried:
…
{
“type”: “colorpicker”,
“name”: “someColor”,
“label”: “Color:”,
“value”: “#452342”,
“offsetLeft”: “10”,
“labelWidth”: “45”,
“imagePath”: “/codebase/imgs/”,
“customColors”: “1”
}
…
as well as some other variances to no avail.
But you can get colorpicker object from the form: var dhxColorPicker = myForm.getColorPicker(“myPicker”);
And set this property to it via script: dhxColorPicker.setCustomColors(colors)
These controls are really great. Their approach is different (and more powerful as a result). I find it difficult to get my head completely around them due to documentation issues.