It works, but it's kinda quirky. For example, as you use items, the number will decrease on the action bar. However, if you open and close your inventory, it bumps it up to 999 again. At least, that's how it seems to work most of the time.
I've also noticed that your dwarves are not invincible...