Language Indepedent Macro

C

coder_arun

Hi,

I am creating a macro sheet using Excel 97 macro functions like:

English:
=WORKBOOK.SELECT("Sample")
=SELECT("R1C1:R10C2")
=RUN("Macro1")
=SELECT("R1C1:R10C2")
=FORMAT.NUMBER("dd-mmm-yyyy")
=RETURN()

Dutch:
=WORKBOOK.SELECT("Sample")
=SELECT("R1K1:R10K2")
=RUN("Macro1")
=SELECT("R1K1:R10K2")
=FORMAT.NUMBER("dd-mmm-jjjj")
=RETURN()

Spanish:
=WORKBOOK.SELECT("Sample")
=SELECT("L1C1:L10C2")
=RUN("Macro1")
=RETURN()


As you can see above for each langauge i have to generate diffren
characters for the macro
English:
R1C1
Italian:
R1K1
Spanish:
L1C1
The characters of the date format also changes for according to th
locale.

Could some one tell me how can i create language independent Macros i
Excel 97 (No VBA macros), such that i generate macros only in english.
And specify the language in some function as a parameter to excel.

Thanks in Advance
Aru
 
K

Kevin McCartney

Hi Arun,

There's no need for these macros, Excel will convert the date format for
you. You can perform this by changing your regional setting to a different
country and see the result for yourself.

HTH
KM
 
B

Bob Phillips

Arun,

In VBA you can write the functions in English, and Excel automatically
manages the localization.

So you write

Range("A1").Value = "=IF(G1="","",VLOOKUP(G1,A:B,2,FALSE))"

and Excel would create say

OM(G1="";"";LETARAD(G1;A:B;2;FALSKT))

in a Swedish version.

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top