kamagra how much to take

There Really Is an Authentication Button Class

I got in an argument today over the phone with a co-worker I used to work with that there was no AuthenticationButton Class. Actually, there is a sealed AuthenticationButton class that inherits from System.Web.UI.Control class, the System.Web.UI.INamingContainer interface, and the Microsoft.SharePoint.WebControls. IDesignTimeHtmlProvider.

To be honest, I only used it in SharePoint 2003, but it doesn’t appear to be deprecated in SharePoint 2007, so I am on the ball. So, how do you use it? Well, it is pretty easy, because its like adding any control to a SharePoint WebPart.

The first that you have to do when creating a Windows SharePoint Services custom component that makes use of the AuthenticationButton class to make the appropriate references. The AuthenticationButton class exists in the Microsoft.SharePoint.WebPartPages namespace, so make the reference:

  1. using Microsoft.SharePoint.WebPartPages;

Then, you have to setup your class to use the Authentication Button, so delcare it:

  1. private AuthenticationButton SharePointAuthButton;

In your CreateChildControls() method, create a new AuthenticationButton, and then add it by using the add method out of the controls class.

  1. protected override void CreateChildControls()
  2. {
  3. SharePointAuthButton = new AuthenticationButton();
  4. Controls.Add(SharePointAuthButton);
  5. }

Its not real fancy, but I am happy because I was right :-) It only happens far and few between!


Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>