G
Guest
I would like to disable a button on the form if the user is not authorized to
use it.
I've created a custom button and would like for each button to know if it
should be enabled or disabled based on another class that would contain the
users authority levels.
I know I can use the on form load event, but I rather test to see if the
user has access to the button during the buttons OnPaint event? If they
don't have access, I'd like to disable the button. So should I use the
OnPaint event for the button, or is there an event that would be more
appropriate.
use it.
I've created a custom button and would like for each button to know if it
should be enabled or disabled based on another class that would contain the
users authority levels.
I know I can use the on form load event, but I rather test to see if the
user has access to the button during the buttons OnPaint event? If they
don't have access, I'd like to disable the button. So should I use the
OnPaint event for the button, or is there an event that would be more
appropriate.