WHAT ARE SAFE CONTROLS, AND WHAT TYPE OF INFORMATION, IS PLACED IN THAT ELEMENT IN A SHAREPOINT WEB.CONFIG FILE?

Awadhendra Tiwari

Total Post:510

Points:2550
Posted by  Awadhendra Tiwari
 2148  View(s)
Ratings:
Rate this:
  1. Awadhendra Tiwari

    Post:510

    Points:2550
    What are safe controls, and what type of information, is placed in that element in a SharePoint web.config file?

    When you deploy a WebPart to SharePoint, you must first make it as a safe control to use within SharePoint in the web.config file. Entries made in the safe controls element of SharePoint are encountered by the SharePointHandler object and will be loaded in the SharePoint environment properly, those not will not be loaded and will throw an error.
    In the generic safe control entry (this is general, there could be more), there is generally the Assembly name, the
    namespace, the public key token numeric, the typename, and the safe declaration (whether it is safe or not). There are other optional elements.

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!