Version 7.6.3.2-android, tag libreoffice-7.6.3.2-android
[LibreOffice.git] / wizards / source / euro / Init.xba
blob9f56c503a347e24ecc801c5e979a7332d4252859
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE script:module PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "module.dtd">
3 <!--
4 * This file is part of the LibreOffice project.
6 * This Source Code Form is subject to the terms of the Mozilla Public
7 * License, v. 2.0. If a copy of the MPL was not distributed with this
8 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
10 * This file incorporates work covered by the following license notice:
12 * Licensed to the Apache Software Foundation (ASF) under one or more
13 * contributor license agreements. See the NOTICE file distributed
14 * with this work for additional information regarding copyright
15 * ownership. The ASF licenses this file to you under the Apache
16 * License, Version 2.0 (the "License"); you may not use this file
17 * except in compliance with the License. You may obtain a copy of
18 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
19 -->
20 <script:module xmlns:script="http://openoffice.org/2000/script" script:name="Init" script:language="StarBasic">Option Explicit
21 REM ***** BASIC *****
23 Public Const SBRANGEUBOUND = 20
24 Public StyleRangeAssignmentList(SBRANGEUBOUND)as String
25 Public SelRangeList(SBRANGEUBOUND) as String
26 Public RangeList(SBRANGEUBOUND) as String
27 Public UnprotectList() as String
28 Public FilterNames(2,1) as String
29 Public bDoUnProtect as Boolean
30 Public bCancelTask as Boolean
32 Public sREADY as String
33 Public sPROTECT as String
34 Public sCONTINUE as String
36 Public sSELTEMPL as String
37 Public sSELCELL as String
38 Public sCURRRANGES as String
39 Public sTEMPLATES as String
41 Public sSOURCEFILE as String
42 Public sSOURCEDIR as String
43 Public sTARGETDIR as String
45 Public sStsPROGRESS as String
46 Public sStsCELLPROGRSS as String
47 Public sStsRELRANGES as String
48 Public sStsRELSHEETRANGES as String
49 Public sStsREPROTECT as String
51 Public sMsgSELDIR as String
52 Public sMsgSELFILE as String
53 Public sMsgTARGETDIR as String
54 Public sMsgNOTTHERE as String
55 Public sMsgDLGTITLE as String
56 Public sMsgUNPROTECT as String
57 Public sMsgPWPROTECT as String
58 Public sMsgWRONGPW as String
59 Public sMsgSHEETPROTECTED as String
60 Public sMsgWARNING as String
61 Public sMsgSHEETSNOPROTECT as String
62 Public sMsgSHEETNOPROTECT as String
63 Public sMsgCHOOSECURRENCY as String
64 Public sMsgPASSWORD as String
65 Public sMsgOK as String
66 Public sMsgCANCEL as String
67 Public sMsgFileInvalid as String
68 Public sMsgNODIRECTORY as String
69 Public sMsgDOCISREADONLY as String
70 Public sMsgFileExists as String
71 Public sMsgCancelConversion as String
72 Public sMsgCancelTitle as String
73 Public sCurrPORTUGUESE as String
74 Public sCurrDUTCH as String
75 Public sCurrFRENCH as String
76 Public sCurrSPANISH as String
77 Public sCurrITALIAN as String
78 Public sCurrGERMAN as String
79 Public sCurrBELGIAN as String
80 Public sCurrIRISH as String
81 Public sCurrLUXEMBOURG as String
82 Public sCurrAUSTRIAN as String
83 Public sCurrFINNISH as String
84 Public sCurrGREEK as String
85 Public sCurrSLOVENIAN as String
86 Public sCurrCYPRIOT as String
87 Public sCurrMALTESE as String
88 Public sCurrSLOVAK as String
89 Public sCurrESTONIAN as String
90 Public sCurrLATVIAN as String
91 Public sCurrLITHUANIAN as String
92 Public sCurrCROATIAN as String
94 Public sPrgsRETRIEVAL as String
95 Public sPrgsCONVERTING as String
96 Public sPrgsUNPROTECT as String
97 Public sInclusiveSubDir as String
99 Public Const SBCOUNTRYCOUNT = 19
100 Public CurMimeType as String
101 Public CurCellCount as Long
102 Public oSheets as Object
103 Public oStyles as Object
104 Public oStyle as Object
105 Public oFormats as Object
106 Public aSimpleStr as String
107 Public nSimpleKey as Long
108 Public aFormat() as Variant
109 Public oRanges as Object
110 Public oRange as Object
111 Public nLanguage as integer
112 Public nFormatLanguage as integer
113 Public aCellFormat as Variant
114 Public oDocument as Object
115 Public StartCol, StartRow, EndCol, EndRow as String
116 Public oSheet as Object
117 Public IntStartCol, IntStartRow, IntEndCol, IntEndRow as integer
118 Public oSelRanges as Object
119 Public nFormatType as Integer
120 Public sFormatCurrency as String
121 Public sFormatLanguage as String
122 Public CurSheetName as String
123 Public oStatusLine as Object
124 Public Const SBRELGET = 50
125 Public StatusValue as Single
126 Public TotCellCount as Long
127 Public StyleIndex as Integer
128 Public RangeIndex as Integer
129 Public CurrIndex as Integer
130 Public ActLangNumber(1) as Integer
131 Public CurExtension(2) as String
132 Public Currfactor as Double
133 Public CurrSymbolList(2) as String
134 Public CurrLanguage as String
135 Public CurrValue(18,5)
136 Public LangIDValue(18,2,2) as String
137 Public PreName as String
138 Public Separator as String
139 Public BitmapDir as String
140 Public TypeIndex as Integer, CSIndex as Integer, LangIndex as Integer, FSIndex as Integer
141 Public oLocale as New com.sun.star.lang.Locale
142 Public sEuroSign as String
143 Public oPointer as Object
144 Public sDocType as String
145 Public bPreSelected as Boolean
146 Public bRecursive as Boolean
147 Public bCancelProtection as Boolean
148 Public CurrRoundMode as Boolean
149 Public bRangeListDefined as Boolean
150 Public bDocHasProtectedSheets as Boolean
151 Public sGOON as String
152 Public sHELP as String
153 Public sCANCEL as String
154 Dim sEnd as String
156 Sub InitializeResources()
157 Dim LocWorkPath as String
158 With DialogModel
159 &apos; Strings that are also needed by the Password Dialog
160 sGoOn = GetResText(&quot;STEP_ZERO_3&quot;)
161 sHelp = GetResText(&quot;STEP_ZERO_1&quot;)
162 sCANCEL = GetResText(&quot;MESSAGES_18&quot;)
163 sEnd = GetResText(&quot;STEP_ZERO_0&quot;)
164 sPROTECT = GetResText(&quot;STEP_ZERO_5&quot;)
165 sCONTINUE = GetResText(&quot;STEP_ZERO_7&quot;)
166 sSELTEMPL = GetResText(&quot;STEP_CONVERTER_6&quot;)
167 sSELCELL = GetResText(&quot;STEP_CONVERTER_7&quot;)
168 sCURRRANGES = GetResText(&quot;STEP_CONVERTER_8&quot;)
169 sTEMPLATES = GetResText(&quot;STEP_CONVERTER_9&quot;)
170 sStsPROGRESS = GetResText(&quot;STATUSLINE_0&quot;)
171 sStsCELLPROGRSS = GetResText(&quot;STATUSLINE_1&quot;)
172 sStsRELSHEETRANGES = GetResText(&quot;STATUSLINE_2&quot;)
173 sStsRELRANGES = GetResText(&quot;STATUSLINE_3&quot;)
174 sStsREPROTECT = GetResText(&quot;STATUSLINE_4&quot;)
175 sREADY = GetResText(&quot;MESSAGES_0&quot;)
176 sMsgSELDIR = GetResText(&quot;MESSAGES_1&quot;)
177 sMsgSELFILE = GetResText(&quot;MESSAGES_2&quot;)
178 sMsgTARGETDIR = GetResText(&quot;MESSAGES_3&quot;)
179 sMsgNOTTHERE = GetResText(&quot;MESSAGES_4&quot;)
180 sMsgDLGTITLE = GetResText(&quot;MESSAGES_5&quot;)
181 sMsgUNPROTECT = GetResText(&quot;MESSAGES_6&quot;)
182 sMsgPWPROTECT = GetResText(&quot;MESSAGES_7&quot;)
183 sMsgWRONGPW = GetResText(&quot;MESSAGES_8&quot;)
184 sMsgSHEETPROTECTED = GetResText(&quot;MESSAGES_9&quot;)
185 sMsgWARNING = GetResText(&quot;MESSAGES_10&quot;)
186 sMsgSHEETSNOPROTECT = GetResText(&quot;MESSAGES_11&quot;)
187 sMsgSHEETNOPROTECT = GetResText(&quot;MESSAGES_12&quot;)
188 sMsgCHOOSECURRENCY = GetResText(&quot;MESSAGES_15&quot;)
189 sMsgPASSWORD = GetResText(&quot;MESSAGES_16&quot;)
190 sMsgOK = GetResText(&quot;MESSAGES_17&quot;)
191 sMsgCANCEL = GetResText(&quot;MESSAGES_18&quot;)
192 sMsgFILEINVALID = GetResText(&quot;MESSAGES_19&quot;)
193 sMsgFILEINVALID = ReplaceString(sMsgFILEINVALID,&quot;%PRODUCTNAME&quot;, GetProductname())
194 SMsgNODIRECTORY = GetResText(&quot;MESSAGES_20&quot;)
195 sMsgDOCISREADONLY = GetResText(&quot;MESSAGES_21&quot;)
196 sMsgFileExists = GetResText(&quot;MESSAGES_22&quot;)
197 sMsgCancelConversion = GetResText(&quot;MESSAGES_23&quot;)
198 sMsgCancelTitle = GetResText(&quot;MESSAGES_24&quot;)
199 sCurrPORTUGUESE = GetResText(&quot;CURRENCIES_0&quot;)
200 sCurrDUTCH = GetResText(&quot;CURRENCIES_1&quot;)
201 sCurrFRENCH = GetResText(&quot;CURRENCIES_2&quot;)
202 sCurrSPANISH = GetResText(&quot;CURRENCIES_3&quot;)
203 sCurrITALIAN = GetResText(&quot;CURRENCIES_4&quot;)
204 sCurrGERMAN = GetResText(&quot;CURRENCIES_5&quot;)
205 sCurrBELGIAN = GetResText(&quot;CURRENCIES_6&quot;)
206 sCurrIRISH = GetResText(&quot;CURRENCIES_7&quot;)
207 sCurrLUXEMBOURG = GetResText(&quot;CURRENCIES_8&quot;)
208 sCurrAUSTRIAN = GetResText(&quot;CURRENCIES_9&quot;)
209 sCurrFINNISH = GetResText(&quot;CURRENCIES_10&quot;)
210 sCurrGREEK = GetResText(&quot;CURRENCIES_11&quot;)
211 sCurrSLOVENIAN = GetResText(&quot;CURRENCIES_12&quot;)
212 sCurrCYPRIOT = GetResText(&quot;CURRENCIES_13&quot;)
213 sCurrMALTESE = GetResText(&quot;CURRENCIES_14&quot;)
214 sCurrSLOVAK = GetResText(&quot;CURRENCIES_15&quot;)
215 sCurrESTONIAN = GetResText(&quot;CURRENCIES_16&quot;)
216 sCurrLATVIAN = GetResText(&quot;CURRENCIES_17&quot;)
217 sCurrLITHUANIAN = GetResText(&quot;CURRENCIES_18&quot;)
218 sCurrCROATIAN = GetResText(&quot;CURRENCIES_19&quot;)
219 .cmdCancel.Label = sCANCEL
220 .cmdHelp.Label = sHELP
221 .cmdBack.Label = GetResText(&quot;STEP_ZERO_2&quot;)
222 .cmdGoOn.Label = sGOON
223 .lblHint.Label = GetResText(&quot;STEP_ZERO_4&quot;)
224 .lblCurrencies.Label = GetResText(&quot;STEP_ZERO_6&quot;)
225 .cmdBack.Enabled = False
226 If .Step = 1 Then
227 .chkComplete.Label = GetResText(&quot;STEP_CONVERTER_0&quot;)
228 .hlnSelection.Label = GetResText(&quot;STEP_CONVERTER_1&quot;)
229 .optCellTemplates.Label = GetResText(&quot;STEP_CONVERTER_2&quot;)
230 .optSheetRanges.Label = GetResText(&quot;STEP_CONVERTER_3&quot;)
231 .optDocRanges.Label = GetResText(&quot;STEP_CONVERTER_4&quot;)
232 .optSelRange.Label = GetResText(&quot;STEP_CONVERTER_5&quot;)
233 sCURRRANGES = GetResText(&quot;STEP_CONVERTER_8&quot;)
234 .lblSelection.Label = sCURRRANGES
235 Else
236 .lblProgress.Label = sStsPROGRESS
237 .hlnExtent.Label = GetResText(&quot;STEP_AUTOPILOT_0&quot;)
238 .optSingleFile.Label = GetResText(&quot;STEP_AUTOPILOT_1&quot;)
239 .optWholeDir.Label = GetResText(&quot;STEP_AUTOPILOT_2&quot;)
240 .chkProtect.Label = GetResText(&quot;STEP_AUTOPILOT_7&quot;)
241 .chkTextDocuments.Label = GetResText(&quot;STEP_AUTOPILOT_10&quot;)
243 sSOURCEFILE = GetResText(&quot;STEP_AUTOPILOT_3&quot;)
244 sSOURCEDIR = GetResText(&quot;STEP_AUTOPILOT_4&quot;)
245 .lblSource.Label = sSOURCEDIR
246 sInclusiveSubDir = GetResText(&quot;STEP_AUTOPILOT_5&quot;)
247 .chkRecursive.Label = sInclusiveSubDir
248 sTARGETDIR = GetResText(&quot;STEP_AUTOPILOT_6&quot;)
249 .lblTarget.Label = STARGETDIR
251 LocWorkPath = GetPathSettings(&quot;Work&quot;)
252 If Not oUcb.Exists(LocWorkPath) Then
253 ShowNoOfficePathError()
254 Stop
255 End If
257 .txtSource.Text = ConvertfromUrl(LocWorkPath)
259 SubstDir = .txtSource.Text
260 .txtTarget.Text = .txtSource.Text
261 .hlnProgress.Label = GetResText(&quot;STEP_LASTPAGE_0&quot;)
262 .lblConfig.Label = GetResText(&quot;STEP_LASTPAGE_3&quot;)
263 sPrgsRETRIEVAL = GetResText(&quot;STEP_LASTPAGE_1&quot;)
264 sPrgsCONVERTING = GetResText(&quot;STEP_LASTPAGE_2&quot;)
265 sPrgsUNPROTECT = GetResText(&quot;STEP_LASTPAGE_4&quot;)
266 End If
267 End With
268 End Sub
270 Sub InitializeLanguages()
271 sEuroSign = chr(8364)
273 &apos; CURRENCIES_PORTUGUESE
274 LangIDValue(0,0,0) = &quot;pt&quot;
275 LangIDValue(0,0,1) = &quot;&quot;
276 LangIDValue(0,0,2) = &quot;-816&quot;
278 &apos; CURRENCIES_DUTCH
279 LangIDValue(1,0,0) = &quot;nl&quot;
280 LangIDValue(1,0,1) = &quot;&quot;
281 LangIDValue(1,0,2) = &quot;-413&quot;
283 &apos; CURRENCIES_FRENCH
284 LangIDValue(2,0,0) = &quot;fr&quot;
285 LangIDValue(2,0,1) = &quot;&quot;
286 LangIDValue(2,0,2) = &quot;-40C&quot;
288 &apos; CURRENCIES_SPANISH
289 LangIDValue(3,0,0) = &quot;es&quot;
290 LangIDValue(3,0,1) = &quot;&quot;
291 LangIDValue(3,0,2) = &quot;-40A&quot;
293 &apos;Spanish modern
294 LangIDValue(3,1,0) = &quot;es&quot;
295 LangIDValue(3,1,1) = &quot;&quot;
296 LangIDValue(3,1,2) = &quot;-C0A&quot;
298 &apos;Spanish katalanic
299 LangIDValue(3,2,0) = &quot;es&quot;
300 LangIDValue(3,2,1) = &quot;&quot;
301 LangIDValue(3,2,2) = &quot;-403&quot;
303 &apos; CURRENCIES_ITALIAN
304 LangIDValue(4,0,0) = &quot;it&quot;
305 LangIDValue(4,0,1) = &quot;&quot;
306 LangIDValue(4,0,2) = &quot;-410&quot;
308 &apos; CURRENCIES_GERMAN
309 LangIDValue(5,0,0) = &quot;de&quot;
310 LangIDValue(5,0,1) = &quot;DE&quot;
311 LangIDValue(5,0,2) = &quot;-407&quot;
313 &apos; CURRENCIES_BELGIAN
314 LangIDValue(6,0,0) = &quot;fr&quot;
315 LangIDValue(6,0,1) = &quot;BE&quot;
316 LangIDValue(6,0,2) = &quot;-80C&quot;
318 LangIDValue(6,1,0) = &quot;nl&quot;
319 LangIDValue(6,1,1) = &quot;BE&quot;
320 LangIDValue(6,1,2) = &quot;-813&quot;
322 &apos; CURRENCIES_IRISH
323 LangIDValue(7,0,0) = &quot;en&quot;
324 LangIDValue(7,0,1) = &quot;IE&quot;
325 LangIDValue(7,0,2) = &quot;-1809&quot;
327 LangIDValue(7,1,0) = &quot;ga&quot;
328 LangIDValue(7,1,1) = &quot;IE&quot;
329 LangIDValue(7,1,2) = &quot;-83C&quot;
331 &apos; CURRENCIES_LUXEMBOURG
332 LangIDValue(8,0,0) = &quot;fr&quot;
333 LangIDValue(8,0,1) = &quot;LU&quot;
334 LangIDValue(8,0,2) = &quot;-140C&quot;
336 LangIDValue(8,1,0) = &quot;de&quot;
337 LangIDValue(8,1,1) = &quot;LU&quot;
338 LangIDValue(8,1,2) = &quot;-1007&quot;
340 &apos; CURRENCIES_AUSTRIAN
341 LangIDValue(9,0,0) = &quot;de&quot;
342 LangIDValue(9,0,1) = &quot;AT&quot;
343 LangIDValue(9,0,2) = &quot;-C07&quot;
345 &apos; CURRENCIES_FINNISH
346 LangIDValue(10,0,0) = &quot;fi&quot;
347 LangIDValue(10,0,1) = &quot;FI&quot;
348 LangIDValue(10,0,2) = &quot;-40B&quot;
350 LangIDValue(10,1,0) = &quot;sv&quot;
351 LangIDValue(10,1,1) = &quot;FI&quot;
352 LangIDValue(10,1,2) = &quot;-81D&quot;
354 &apos; CURRENCIES_GREEK
355 LangIDValue(11,0,0) = &quot;el&quot;
356 LangIDValue(11,0,1) = &quot;GR&quot;
357 LangIDValue(11,0,2) = &quot;-408&quot;
359 &apos; CURRENCIES_SLOVENIAN
360 LangIDValue(12,0,0) = &quot;sl&quot;
361 LangIDValue(12,0,1) = &quot;SI&quot;
362 LangIDValue(12,0,2) = &quot;-424&quot;
364 &apos; CURRENCIES_CYPRIOT
365 LangIDValue(13,0,0) = &quot;el&quot;
366 LangIDValue(13,0,1) = &quot;CY&quot;
367 LangIDValue(13,0,2) = &quot;-408&quot;
369 &apos; CURRENCIES_MALTESE
370 LangIDValue(14,0,0) = &quot;mt&quot;
371 LangIDValue(14,0,1) = &quot;MT&quot;
372 LangIDValue(14,0,2) = &quot;-43A&quot;
374 &apos; CURRENCIES_SLOVAK
375 LangIDValue(15,0,0) = &quot;sk&quot;
376 LangIDValue(15,0,1) = &quot;SK&quot;
377 LangIDValue(15,0,2) = &quot;-41B&quot;
379 &apos; CURRENCIES_ESTONIAN
380 LangIDValue(16,0,0) = &quot;et&quot;
381 LangIDValue(16,0,1) = &quot;ET&quot;
382 LangIDValue(16,0,2) = &quot;-425&quot;
384 &apos; CURRENCIES_LATVIAN
385 LangIDValue(17,0,0) = &quot;lv&quot;
386 LangIDValue(17,0,1) = &quot;LV&quot;
387 LangIDValue(17,0,2) = &quot;-426&quot;
388 &apos; and Latgalian
389 LangIDValue(17,1,0) = &quot;ltg&quot;
390 LangIDValue(17,1,1) = &quot;LV&quot;
391 LangIDValue(17,1,2) = &quot;-64B&quot;
393 &apos; CURRENCIES_LITHUANIAN
394 LangIDValue(18,0,0) = &quot;lt&quot;
395 LangIDValue(18,0,1) = &quot;LT&quot;
396 LangIDValue(18,0,2) = &quot;-427&quot;
398 &apos; CURRENCIES_CROATIAN
399 LangIDValue(19,0,0) = &quot;hr&quot;
400 LangIDValue(19,0,1) = &quot;HR&quot;
401 LangIDValue(19,0,2) = &quot;-41A&quot;
403 End Sub
407 Sub InitializeCurrencies()
408 Dim i as Integer
409 GoOn = True
411 CurrValue(0,0) = sCurrPORTUGUESE
412 &apos; real conversion rate
413 CurrValue(0,1) = 200.482
414 &apos; rounded conversion rate
415 CurrValue(0,2) = 200
416 CurrValue(0,3) = &quot;Esc.&quot;
417 CurrValue(0,4) = &quot;Esc.&quot;
418 CurrValue(0,5) = &quot;PTE&quot;
420 CurrValue(1,0) = sCurrDUTCH
421 &apos; real conversion rate
422 CurrValue(1,1) = 2.20371
423 &apos; rounded conversion rate
424 CurrValue(1,2) = 2
425 CurrValue(1,3) = &quot;F&quot;
426 CurrValue(1,4) = &quot;fl&quot;
427 CurrValue(1,5) = &quot;NLG&quot;
429 CurrValue(2,0) = sCurrFRENCH
430 &apos; real conversion rate
431 CurrValue(2,1) = 6.55957
432 &apos; rounded conversion rate
433 CurrValue(2,2) = 7
434 CurrValue(2,3) = &quot;F&quot;
435 CurrValue(2,4) = &quot;F&quot;
436 CurrValue(2,5) = &quot;FRF&quot;
438 CurrValue(3,0) = sCurrSPANISH
439 &apos; real conversion rate
440 CurrValue(3,1) = 166.386
441 &apos; rounded conversion rate
442 CurrValue(3,2) = 170
443 CurrValue(3,3) = &quot;Pts&quot;
444 CurrValue(3,4) = &quot;Pts&quot;
445 CurrValue(3,5) = &quot;ESP&quot;
447 CurrValue(4,0) = sCurrITALIAN
448 &apos; real conversion rate
449 CurrValue(4,1) = 1936.27
450 &apos; rounded conversion rate
451 CurrValue(4,2) = 2000
452 CurrValue(4,3) = &quot;L.&quot;
453 CurrValue(4,4) = &quot;L.&quot;
454 CurrValue(4,5) = &quot;ITL&quot;
456 CurrValue(5,0) = sCurrGERMAN
457 &apos; real conversion rate
458 CurrValue(5,1) = 1.95583
459 &apos; rounded conversion rate
460 CurrValue(5,2) = 2
461 CurrValue(5,3) = &quot;DM&quot;
462 CurrValue(5,4) = &quot;DM&quot;
463 CurrValue(5,5) = &quot;DEM&quot;
465 CurrValue(6,0) = sCurrBELGIAN
466 &apos; real conversion rate
467 CurrValue(6,1) = 40.3399
468 &apos; rounded conversion rate
469 CurrValue(6,2) = 40
470 CurrValue(6,3) = &quot;FB&quot;
471 CurrValue(6,4) = &quot;BF&quot;
472 CurrValue(6,5) = &quot;BEF&quot;
474 CurrValue(7,0) = sCurrIRISH
475 &apos; real conversion rate
476 CurrValue(7,1) = 0.787564
477 &apos; rounded conversion rate
478 CurrValue(7,2) = 0.8
479 CurrValue(7,3) = &quot;IR£&quot;
480 CurrValue(7,4) = &quot;£&quot;
481 CurrValue(7,5) = &quot;IEP&quot;
483 CurrValue(8,0) = sCurrLUXEMBOURG
484 &apos; real conversion rate
485 CurrValue(8,1) = 40.3399
486 &apos; rounded conversion rate
487 CurrValue(8,2) = 40
488 CurrValue(8,3) = &quot;F&quot;
489 CurrValue(8,4) = &quot;F&quot;
490 CurrValue(8,5) = &quot;LUF&quot;
492 CurrValue(9,0) = sCurrAUSTRIAN
493 &apos; real conversion rate
494 CurrValue(9,1) = 13.7603
495 &apos; rounded conversion rate
496 CurrValue(9,2) = 15
497 CurrValue(9,3) = &quot;öS&quot;
498 CurrValue(9,4) = &quot;S&quot;
499 CurrValue(9,5) = &quot;ATS&quot;
501 CurrValue(10,0) = sCurrFINNISH
502 &apos; real conversion rate
503 CurrValue(10,1) = 5.94573
504 &apos; rounded conversion rate
505 CurrValue(10,2) = 6
506 CurrValue(10,3) = &quot;mk&quot;
507 CurrValue(10,4) = &quot;mk&quot;
508 CurrValue(10,5) = &quot;FIM&quot;
510 CurrValue(11,0) = sCurrGREEK
511 &apos; real conversion rate
512 CurrValue(11,1) = 340.750
513 &apos; rounded conversion rate
514 CurrValue(11,2) = 400
515 CurrValue(11,3) = chr(916) &amp; chr(961) &amp; chr(967)
516 CurrValue(11,4) = chr(916) &amp; chr(961) &amp; chr(967)
517 CurrValue(11,5) = &quot;GRD&quot;
519 CurrValue(12,0) = sCurrSLOVENIAN
520 &apos; real conversion rate
521 CurrValue(12,1) = 239.64
522 &apos; rounded conversion rate
523 CurrValue(12,2) = 240
524 CurrValue(12,3) = &quot;SIT&quot;
525 CurrValue(12,4) = &quot;SIT&quot;
526 CurrValue(12,5) = &quot;SIT&quot;
528 CurrValue(13,0) = sCurrCYPRIOT
529 &apos; real conversion rate
530 CurrValue(13,1) = 0.585274
531 &apos; rounded conversion rate
532 CurrValue(13,2) = 0.6
533 CurrValue(13,3) = &quot;£C&quot;
534 CurrValue(13,4) = &quot;£&quot;
535 CurrValue(13,5) = &quot;CYP&quot;
537 CurrValue(14,0) = sCurrMALTESE
538 &apos; real conversion rate
539 CurrValue(14,1) = 0.429300
540 &apos; rounded conversion rate
541 CurrValue(14,2) = 0.4
542 CurrValue(14,3) = chr(8356)
543 CurrValue(14,4) = &quot;Lm&quot;
544 CurrValue(14,5) = &quot;MTL&quot;
546 CurrValue(15,0) = sCurrSLOVAK
547 &apos; real conversion rate
548 CurrValue(15,1) = 30.1260
549 &apos; rounded conversion rate
550 CurrValue(15,2) = 30
551 CurrValue(15,3) = &quot;Sk&quot;
552 CurrValue(15,4) = &quot;Sk&quot;
553 CurrValue(15,5) = &quot;SKK&quot;
555 CurrValue(16,0) = sCurrESTONIAN
556 &apos; real conversion rate
557 CurrValue(16,1) = 15.6466
558 &apos; rounded conversion rate
559 CurrValue(16,2) = 16
560 CurrValue(16,3) = &quot;kr&quot;
561 CurrValue(16,4) = &quot;kr&quot;
562 CurrValue(16,5) = &quot;EEK&quot;
564 CurrValue(17,0) = sCurrLATVIAN
565 &apos; real conversion rate
566 CurrValue(17,1) = 0.702804
567 &apos; rounded conversion rate
568 CurrValue(17,2) = 0.7
569 CurrValue(17,3) = &quot;Ls&quot;
570 CurrValue(17,4) = &quot;Ls&quot;
571 CurrValue(17,5) = &quot;LVL&quot;
573 CurrValue(18,0) = sCurrLITHUANIAN
574 &apos; real conversion rate
575 CurrValue(18,1) = 3.45280
576 &apos; rounded conversion rate
577 CurrValue(18,2) = 3.5
578 CurrValue(18,3) = &quot;Lt&quot;
579 CurrValue(18,4) = &quot;Lt&quot;
580 CurrValue(18,5) = &quot;LTL&quot;
582 CurrValue(19,0) = sCurrCROATIAN
583 &apos; real conversion rate
584 CurrValue(19,1) = 7.53450
585 &apos; rounded conversion rate
586 CurrValue(19,2) = 7.5
587 CurrValue(19,3) = &quot;kn&quot;
588 CurrValue(19,4) = &quot;kn&quot;
589 CurrValue(19,5) = &quot;HRK&quot;
591 i = -1
592 CurrSymbolList(0) = &quot;&quot;
593 CurrSymbolList(1) = &quot;&quot;
594 InitializeCurrencyValues(CurrIndex)
595 End Sub
598 Sub InitializeControls()
599 If CurrIndex = -1 Then
600 If DialogModel.Step = 1 Then
601 EnableStep1DialogControls(True, False, False)
602 ElseIf DialogModel.Step = 2 Then
603 EnableStep2DialogControls(True)
604 End If
605 End If
606 End Sub
609 Sub InitializeConverter(oLocale, iDialogPage as Integer)
610 Dim Isthere as Boolean
611 bCancelProtection = False
612 bRangeListDefined = False
613 PWIndex = -1
614 If iDialogPage = 1 Then
615 ToggleWindow(False)
616 sDocType = Tools.GetDocumentType(ThisComponent)
617 If sDocType = &quot;sCalc&quot; Then
618 bDocHasProtectedSheets = CheckSheetProtection(oSheets)
619 End If
620 oStatusline = ThisComponent.GetCurrentController.GetFrame.CreateStatusIndicator()
621 End If
622 DialogConvert = LoadDialog(&quot;Euro&quot;, &quot;DlgConvert&quot;)
623 DialogModel = DialogConvert.Model
624 DialogPassword = LoadDialog(&quot;Euro&quot;, &quot;DlgPassword&quot;)
625 PasswordModel = DialogPassword.Model
626 DialogModel.Step = iDialogPage
627 InitializeResources()
628 InitializeLanguages()
629 InitializeLocales(oLocale)
630 InitializeCurrencies()
631 InitializeControls()
632 BitmapDir = GetOfficeSubPath(&quot;Template&quot;, &quot;../wizard/bitmap&quot;)
633 If BitmapDir = &quot;&quot; Then
634 Stop
635 End If
636 FillUpCurrencyListbox()
637 DialogModel.imgPreview.ImageUrl = BitmapDir &amp; &quot;euro_&quot; &amp; DialogModel.Step &amp; &quot;.png&quot;
638 DialogConvert.Title = sMsgDLGTITLE
639 DialogModel.cmdGoOn.DefaultButton = True
640 If iDialogPage = 1 Then
641 ToggleWindow(True)
642 End If
643 End Sub
646 Sub InitializeCurrencyValues(CurrIndex)
647 If CurrIndex &lt;&gt; -1 Then
648 CurrLanguage = CurrValue(CurrIndex,0)
649 CurrFactor = CurrValue(CurrIndex,1)
650 CurrSymbolList(0) = CurrValue(CurrIndex,3)
651 CurrSymbolList(1) = CurrValue(CurrIndex,4)
652 CurrSymbolList(2) = CurrValue(CurrIndex,5)
653 End If
654 End Sub
657 Function InitializeLocales(oLocale) as Boolean
658 Dim i as Integer, n as Integer, m as Integer
659 Dim sLanguage as String, sCountry as String
660 Dim bTakeThisLocale as Boolean
661 sLanguage = oLocale.Language
662 sCountry = oLocale.Country
663 For n = 0 To SBCOUNTRYCOUNT - 1
664 For m = 0 TO 1
665 If DialogModel.Step = 2 Then
666 bTakeThisLocale = LangIDValue(n,m,0) = sLanguage
667 Else
668 bTakeThisLocale = LangIDValue(n,m,0) = sLanguage
669 End If
670 If bTakeThisLocale Then
671 CurrIndex = n
672 For i = 0 To 2
673 CurExtension(i) = LangIDValue(CurrIndex,i,2)
674 Next i
675 InitializeLocales = True
676 Exit Function
677 End If
678 Next m
679 Next n
680 CurrIndex = -1
681 InitializeLocales = False
682 End Function
683 </script:module>