Probably another easy question, but I've been working on it this morning and haven't been able to get it to work.

I have a site definition that I am attempting to move the string literals to a resource file. I have been attempting to work from an the example of how this is done for the existing onet files of the built-in templates.

I have tried adding the resource file to a number of places, under site definition, as a projec resource under properties and as a basic resource file for the project. Adding the resource file under site definition sets the deployment path to the resources folder as it should be so I'm thinking that is likely the correct place.

Is there somewhere I need to register the resource file? The examples I'm working from are for onet files, so is it even possible with webtemp files? What am I missing?


You can't have resources files in webtemp*.xml files... Those are already localized with the folder that contains them.

For example, check the file webtempsps.xml in the path C:\Program Files\Common Files\microsoft shared\Web Server Extensions\12\TEMPLATE\1033\XML. You will see that every string literals are in fact real string, and not in the format $Resources:core,.... This being said, for every language you want to make your template available, you will have to provide a webtemp*.xml that will be translated in the desired language. You need to provide it in french and in english? You will need 2 files, each one in the good culture id folder (1033 and 1036).

It can be easily understood, because it is also the source of your available templates for each language. SharePoint bases his query on those files in the C:\Program Files\Common Files\microsoft shared\Web Server Extensions\12\TEMPLATE{LANGID}\XML folder.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.