I was creating a materpage when I got following error on publishing my masterpage:
CS0030: Cannot convert type "Microsoft.SharePoint.Webcontrols.Scriptblock" to "System.Web.UI.IAttributeAccessor".
The solution of this error was hidden in warning of debug.When I check the content of my masterpage I found some extra properties added to ScriptBlock tag. My tag looked like below:
<SharePoint:ScriptBlock runat="server" __designer:Preview="<script
type="text/javascript">// <![CDATA[
var g_Workspace = "s4-workspace"; // ]]>
</script>" __designer:Values="<P N='ID' T='ctl09' /><P
N='Page' ID='1' /><P N='TemplateControl'
ID='2' /><P N='AppRelativeTemplateSourceDirectory' R='-
1' />"></SharePoint:ScriptBlock>
I make it simple like below and my page was working like a charm.
<SharePoint:ScriptBlock ID="ScriptBlock2" runat="server" ></SharePoint:ScriptBlock>
Subscribe to:
Post Comments (Atom)
-
In last blog we learn how can we enable footer on SharePoint Online Modern Communication site. If you have not gone through that you can use...
-
One of our client wanted to show Employee Directory and our first suggestion was to build custom SPFx which will fetch data from Azure AD or...
-
Issue : Recently there was an issue we face while training React. Generally we give training using video series on YouTube but this time we ...
No comments:
Post a Comment