Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Testing Permission in COM+

Status
Not open for further replies.

entaroadun

Programmer
Sep 27, 2002
583
US
How do I test whether or not a method can be called on a particular COM+ object?

I am creating a COM+ application to support an intranet web site. I would like to enable/disable buttons and hyperlinks on the site based on the user's security settings. However, I don't want to use any programmatic security; declarative security meets the need.

How do I test whether or not the user can call the method without actually calling the method?
 
Directly? You can't.
What I suggest is put in a dummy method that returns true
Put in error hanling if you make the call and it errors then they don't have access to that interface. Make sure you put the method in all the interfaces you want to use like this.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top