Getting started with V0.1 (alpha)
You need VS 2010 (should work with 2008 as well if you don't use the Sample project)
Donwnload the binary package and the Sample project (Version 0.1 (alpha)
and unpack both to a directory of your choice.
2. Start BLocTestApp.exe from the Binary package
3. Click 'Open project' and select the 'BLocSampleApp.csproj' from the Sample app
You will get an Error-Message when you open a Project file for the 1st time, because some BLoc specific properties are missing.
By pressing 'Yes" the default values are set.
You should see something like this now:
Select the desired 'Original culture' by pressing on the ellipsys button next to it and uncheck the 'Orig. culture in satelite assembly' if you want to have it in the main assembly.
You should leave the other settings as they are for now.
4. Update C# project file
Press the 'Apply to VS Project file' button to update the prioject file.
This is what happens here:
If 'Orig. culture in satelite assembly' was checked then the entry '<UICulture>' is added to the project file.
Else the the '<BLoc_OriginalCulture>' property is added.
The '<BLoc_TranslationFilePath>' is added.
The '<LocalizationDirectivesToLocFile>' is added
A Pre- and Post-build event is added.
The assembly attribute 'NeutralResourcesLanguage' is set correctly in the 'AssemblyInfo.cs' file.
(All files will be backuped before modification)
You can close the BLoc Project properties dialog now.
5. Build Sample Application
Open the 'BLocSampleApp.sln' in VS 2010 and build it (as Debug for now).
6. Go through the workflow in the TestApp one time
7. Set final BLoc Project settings
- Check and/or update the UID's (this is done with the msbuild tool)
- if any UID's have changed, then build the SampleApp again (would have happend here for sure)
- Parse the assembly (this is done by the LocBamlForBLoc tool (which is based on the MS LocBaml.exe) and will create the .bloct file)
- Open the Translation editor with the 'Translate texts' button
- You need to add a target languare here before you can continue. Click the '+' button in the 'Misc' group next to the 'Language' combo box and select a language. Then add some translations, save and close the editor
- Click on 'Generate satelite assemblies' to do so. If you start the Sample App now, it should be translated (if the new target language you have added is your windows language)
You should set some additional settings now.
Click on 'Edit project settings' and set the following properties:
: set as you wish, but you should set at least 'Check UID's'
: You should check 'Generate satelite assemblies' to be sure that the satelite assemblies are up to date always.
Now if you compile the Sample app again the UID's will be checked or updated and the satelite assemblies will be generated automatically.
You only need go back to the BLocTestApp when you want to translate some new texts.
Which text is set if it is not translated
Choosing the right text is a 3 step process:
1. Take text from target language
2. If text for target language is not defined and culture is like 'de-DE' then look also in culture 'de'
3. If text is still empty take original text
This procedure makes sure, that there will always be a text, even if it is not translated so far.
Also if most of texts are same for all 'de-*' cultures you can add 'de', 'de-DE', 'de-CH', .. as target language and translate only the different ones for the more specific cultures.