Adding SharePoint SafeControl Element using Visual Studio 2010 and replaceable parameters

While trying to use my custom layouts page, I received an exception that indicated that my custom class was not registered as a safecontrol in the web.config.

Process information:
Process ID: 5272
Process name: w3wp.exe
Account name: DEV\spAppPool

Exception information:
Exception type: HttpParseException
Exception message: Could not load type 'Capgemini.SharePoint.Pex.Example.Layouts.Capgemini.SharePoint.Pex.Example.@default'.

I was confused, didn't visual studio created the SafeControls elements for me? WSPBuilder did it for me in the past so why won't visual studio do it for me?

Actually it can but it doesn't by default, Microsoft provided a nice and easy visual studio interface for us. So here it goes…

1. Open package.package in your visual studio project
2. Notice the 3 tabs (Design,Advanced and Manifest), Click on the manifest tab
3. You

VN:F [1.9.22_1171]
Rating: 0.0/10 (0 votes cast)
VN:F [1.9.22_1171]
Rating: 0 (from 0 votes)