This topic contains the following sections:
Introduction
Intersoft Solutions has taken important strategy in localization capability of all its products.
This version allows you to customize all textual elements available in WebGrid's UI, from common text such as Ready, Refresh etc to context menu. The new localization feature works in conjunction with the LanguageMode which is also a new property added to the TextSettings object. There are three language modes that you can use to internationalize WebGrid efficiently:
-
Default mode
The default language file will be used regardless of any settings.
-
Inherit from Culture mode
The control will pick the language based on the specified Culture in WebGrid level or Thread level. When the language file cannot be found, it will fallback to use the default language file.
-
UseCustom mode
You will decide which language exactly that the WebGrid will use, regardless of any culture settings. If the language file cannot be found, it will fallback to use the default language file.
For greater flexibility, the common text settings are still customizable per grid's instance and will override any of the language mode above. The default localization folder is inside ScriptFolder and needs to be shipped along with your application.
Batch Update Localization
The new batch update feature in WebGrid 7 introduces a dozens of new User Interface elements, which contains many new textual settings as well.
As in good tradition of WebGrid, all textual settings are customizable according to the culture specified by developer. Each textual setting can also be overridden individually. You can find the complete text settings in default.xml which is located in the Localization folder.
The following table lists the new text settings that you can customize.
Category | Text Setting Key | Default Text Setting Value (English) |
CommonText | PendingChanges | {0} pending change(s). |
DeletedRowNoEdit | Row marked as deleted cannot be modified. | |
DeletedRowNoExpand | Row marked as deleted cannot be expanded. | |
BatchUpdateSuccess | All changes have been successfully updated to server. | |
BatchUpdateSuccessWithPartialErrors | One or more changes are not updated due to server errors. | |
MessageBoxText | UnsavedPendingChanges | You have made one or more changes on WebGrid records. Any unsaved changes will lose. |
NotifyPendingChanges | There are {0} unsaved pending changes. Click Accept Changes button below to save changes. | |
UndoPendingChanges | Are you sure you want to undo all pending changes? | |
UndoSelectedPendingChanges | Are you sure you want to undo selected pending changes? | |
DeletedRowEditException | You cannot make changes to the row which parent has been marked as deleted. | |
DuplicateKeyException | The pending changes already contain a record with key '{0}' | |
PrimaryKeyEditException | Modification on primary key's field of pending changes is not allowed. | |
BatchUpdateException | An exception has occurred while processing batch update. please correct or undo your changes. \n\Exception details:\n{0} | |
BatchUpdatePartialException | WebGrid failed to update {0} out of {1} changes due to errors. Please review and correct your changes. \n\nThe following records were not updated:\n{2} | |
Tooltip | ModifiedRowState | Modified row |
AddedRowState | Added row | |
DeletedRowState | Deleted row | |
PendingChangesEmpty | There are no pending changes | |
PendingChangesExisted | There are {0} pending changes: {1} insert(s), {2} edit(s), {3} delete(s) | |
ReviewChanges | Review Pending Changes | |
UndoChanges | Undo All Changes | |
AcceptChanges | Accept All Changes | |
ContextMenu/Row | UndoSelection | Undo Selection |
DeleteSelection | Delete Selection |
Note: You may find empty text entries when using languages other than English. If you found empty entries on the language and culture that you are familiar with, please help us to translate the entries using the default.xml as the template and send it to feedback@intersoftpt.com. |
Deployment
By default, language files are stored in LocalizationFolder which has default value "/CommonLibrary/WebGrid/V8_0_7200/Localization". Intersoft's products have a concept of "centralized deployment" where client scripts and all supporting files are placed in "CommonLibrary" folder. With this concept, developers can easily deploy web applications along with Intersoft's products by copying only "CommonLibrary" folder to the production server. The CommonLibrary needs to be mapped as IIS Virtual Directory in production server.
Features that depend on centralized "CommonLibrary" concept by default are Localization Manager with its XML language files and CustomEditors with its custom editor definitions and supporting client files.
Getting Started
Getting Started
Overview
WebGrid Features Overview
Other Resources
Walkthrough Topics
How-to Topics