StrataFrame Forum

Deny Action Message

http://forum.strataframe.net/Topic5930.aspx

By Tim Dol - 1/18/2007

I created a permission for a button on my form.  In the Denied Action section I set the Action to 'message key' and entered the message key.

When the user clicks on the button I can't figure out how to trigger the denied action message.. or can you do this with one condition?

If SecurityBasics.CurrentUser.GetPermission("save_Layout").Action = PermissionAction.Grant The

Do stuff....

else

Show Denied Message.

 

Thanks
Tim

 

 

 

By Trent L. Taylor - 1/18/2007

Since you are testing on this manually you will need to just call the denied message manually as well.  The messages are automatically displayed when they are associated with a form property, for example.  When you test manually you are just getting the action of the permission but the message it not automatically launched.

Just call the ShowMessageByKey() manually to display your denied message.