Quantcast
Channel: SharePoint 2013 - Development and Programming forum
Viewing all articles
Browse latest Browse all 25064

Resource file entry not accessible in a custom sharepoint solution (elements.xml)

$
0
0

In SharePoint solution added a module to create search center results page.
I am adding components to it through elements.xml.
I am trying to reference a resource file entry hosted in \14\Config\Resources. The resource file is also in the web application App_GlobalResource.
A sample webpart entered in it is shown below.

<AllUsersWebPart WebPartZoneID="TopZone" WebPartOrder="2">
        <![CDATA[     <WebPart xmlns="http://schemas.microsoft.com/WebPart/v2">   <Assembly>Microsoft.Office.Server.Search, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c</Assembly>   <TypeName>Microsoft.Office.Server.Search.WebControls.SearchSummaryWebPart</TypeName>    <Title>$Resources:Microsoft.Office.Server.Search,SearchSummaryWP_Title;</Title>    <Description>$Resources:MyResource,MyMessage;</Description>     <PartOrder>1</PartOrder>   <FrameType>None</FrameType>  <AllowMinimize>true</AllowMinimize>   <AllowRemove>true</AllowRemove>    <IsVisible>true</IsVisible>
     </WebPart>
     ]]>
      </AllUsersWebPart>

However, the line
<Description>$Resources:MyResource,MyMessage;</Description>

does not retrieve the entry from the resource file "MyResource". The output prints the expression $Resources:MyResource,MyMessage;

Any suggestion will be appreciated. Thanks,

 


Viewing all articles
Browse latest Browse all 25064

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>