comp2_head.gif (12369 bytes)

nav.gif (6067 bytes)

 

Resource File With One String Table 

One of the simplest approaches to localization is to use a resource file with only one string table. There is almost no additional coding required since resource file support is built into Visual Basic. Each language is allocated a block of string that fall within a specific range of resource ID numbers. A typical project might allocate blocks of 10,000 strings per language. For example, English might be for ID numbers 0-9,999, Italian for 10,000-19,999 and German for 20,000-39,999. A language offset variable can be used to index into the appropriate block of strings as shown below:


              lBlockOffset = 20000  'Select German strings.
          sMsg = LoadResString(ID + lBlockOffset)
              

 Advantages

  • Very simple design approach.

  • Language can be changed at runtime without rebooting.

Disadvantages

  • One resource file contains all languages, so your EXE file can become rather large if many languages are supported.

  • Any changes to translated strings requires a recompile and re-release.

  • Product release must wait until all translations have been completed.

Microsoft demonstrates this approach with their ATM.VBP project that can be found in the source code examples included with Visual Basic 6.0. The resource file from this project makes the strategy obvious. In this example, the block offset variable would be set to 80 in order to select the German strings.

 

 

16

Welcome

17

Please enter your pin number:

18

Please choose an account:

19

Checking account

20

Savings Account

21

Please enter an amount:

22

OK

23

Your transaction is being processed...

24

Thank you for using our ATM

25

The following amount will be withdraw from your:

26

US Dollars

 

 

 

 

48

Bienvenue

49

Veuillez entrer votre code:

50

Veuillez choisir un compte:

51

Compte chèque

52

Compte épargne

53

Veuillez entrer le montant:

54

OK

55

Votre transaction est en cours de traitement...

56

Merci d'avoir utilisé notre guichet automatique de banque

57

Le montant suivant va être débité de votre :

58

Francs Français

 

 

 

 

80

Willkommen

81

Bitte geben Sie Ihre Geheimnummer ein:

82

Bitte wählen Sie ein Konto aus:

83

Girokonto

84

Sparbuch

85

Bitte geben Sie einen Betrag ein:

86

OK

87

Ihr Auftrag wird bearbeitet...

88

Vielen Dank daß Sie unseren Geldautomaten verwendet haben.

89

Die folgende Summe wird abgebucht von Ihrem:

90

DM

 

 

 

 

112

Benvenuti

113

Digitare il proprio codice segreto:

114

Scegliere il tipo di conto:

115

Conto corrente

116

Libretto di risparmio

117

Digitare la cifra richiesta:

118

Attendere

119

La vostra operazione è in corso di esecuzione...

120

Grazie e arrivederci

121

La seguente cifra verrà prelevata dal vostro:

122

Lire Italiane

 

 

 

 

144

Bienvenido

145

Por favor, ingrese su número de identificación secreto:

146

Por favor, elija una cuenta:

147

Conto corrente

148

Cuenta de ahorros

149

Por favor, ingrese un importe:

150

Aceptar

151

Su transacción se está procesando...

152

Le agradecemos que haya usado nuestro cajero automático

153

La siguiente cantidad será retirada de su:

154

Pesetas

NOTE: This table is copyright protected by Microsoft.

 

 


Home | Products | Contact Us | FAQs | What's New | Services | Localization Info | Search

For comments about the site, contact the Webmaster
Copyright © 1999 Resource Mining Incorporated.  All rights reserved.

Page last updated: May 03, 2003