Listen select event of grid - hide gray, show red. After reloading grid, or if grid store becomes empty - do the opposite. But if think you must use one button with css styles for disabled/enabled controls and setDisabled method. Cause logically it's two states of the one button.
Extjs4 disable "Delete" button by default but when select any row enable the button
Question
I have two "delete" button on top of a grid, one is red another is gray. When no row selected, the button is the gray one. Otherwise, it shows the red one. How to do that using Extjs4?
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow