how to change button image dynamically when some data is loading from server.After completing loading i want previous image.
You can change any property in config of button and call button.refresh() to force repainting
I am setting a button with an empty image. in my logic code, I reference the image by id, and use addCss like this:
webix.html.addCss($$(“buttonId”).getNode(),“cssWithBackgroundImage”);
However, the background image in my .cssWithBackgroundImage is NOT updating the button’s image, even after I call $$(“buttonId”).refresh();
@billtricarico hi, could you please provide the snippet of the issue?
As far as I can see, your code works well, but the background repeats:
http://webix.com/snippet/029e4e56
You can apply the button
definition (with some background-related properties): http://webix.com/snippet/10e9502f
Or define
an image instead of applying CSS: http://webix.com/snippet/bb8429f0