Welcome to MSDN Blogs Sign in | Join | Help

Michael Yeager's MSDN Blog

A stigmergic trail of SharePoint, asp.net and Silverlight Solutions
Cannot convert type 'Microsoft.SharePoint.WebControls.DelegateControl' to 'System.Web.UI.IAttributeAccessor'

Unfortunately I have seen this error too many times. In my case it is regarding a SharePoint master page customization, and I believe it is related to editing the master page in SharePoint designer. Maybe it only occurs when you edit the page and then try saving it back to the Globals or some other folder, haven't confirmed exaclty the steps that cause it...

But the way to fix it is to open the master page in notepad and you'll see a big chunk of html that is commented out. Delete that chunk, and the master page will work properly again. [The next time it occurs I'll come back and clean up this entry with more specifics...]

Posted: Friday, October 05, 2007 9:24 AM by mty

Comments

Andrew Kinnear said:

From what I can see, copying code out of SP designer changes the code. For instance, the following code:

<asp:ContentPlaceHolder id="PlaceHolderPageTitle" runat="server" ></asp:ContentPlaceHolder>

Is changed to:

<asp:ContentPlaceHolder id=PlaceHolderPageTitle

runat="server" ></asp:ContentPlaceHolder>

Anyway, that's my 2 cents worth.

# January 7, 2009 2:32 AM

Liz Elizondo said:

Thank you sooooo much!  I would have never guessed that was the issue.  I just got this today and it was on a custom master page that was modified in SP Designer.  Sure enough when I opened it in NotePad there was a commented out code on a Delegate Control.  Deleted it and the error went away.

# January 29, 2009 11:17 AM
Leave a Comment

(required) 

(required) 

(optional)

(required) 

  
Enter Code Here: Required

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Page view tracker