Welcome to the HP Support Community. This is a great place to get support, find answers and tips to your technical queries. I have reviewed your post and I understand, you are trying to disable the DPI button on the mouse.
Don't worry, I'm here to help!
I'm afraid, the DPI cannot be disabled but what you can do here is decrease the sensitivity.