Everything SharePoint/Silverlight/WP7

My continuous learning of SharePoint, Silverlight, WP7 Development, Office, VSTO, C#…

Archive for January 29th, 2008

Customize application.master

Posted by Steve Pietrek on January 29, 2008

I have been doing some research on customizing application.master. I found a good KB on Microsoft’s web site listing two ways to customize application.master.

  1. Customize the files in the Layouts folder (recommended)
  2. Create a custom Layouts folder

The two methods above work well.

I have been messing around with an application development method using a feature, HttpModule, and SPWebConfigModification. The premise of the feature is for every page, in the PreInit event, I check to see if the page’s current MasterPageFile is application.master. If it is, I set the MasterPageFile to my custom application.master. I plan on blogging on this method soon.

Posted in SPAdmin | 1 Comment »

Error: Cannot convert type ‘Microsoft.SharePoint.WebControls.DelegateControl’ to ‘System.Web.UI.IAttributeAccessor’

Posted by Steve Pietrek on January 29, 2008

Today I was modifying application.master and ran into the following error:

“Cannot convert type ‘Microsoft.SharePoint.WebControls.DelegateControl’ to ‘System.Web.UI.IAttributeAccessor’”

Instead of following my own advice on disabling My Site and My Links, I commented out the two lines in the custom Master File I created. I copied the commented code from my custom Master File to application.master. When I refreshed the page, I received the error above. At least for the two lines I commented out, SPD adds characters for spaces and such. It does not cause any issues for end-user Master Pages but it does for application.master. Figuring that was the issue, I put back the correct code and uncommented. Error went away.  

Posted in SPErrors | Leave a Comment »

 
Follow

Get every new post delivered to your Inbox.