Problems with boolean values using non English versions of Excel

SQL*XL
home


Symptoms:

Macros generated with SQL*XL and Excel's macro recorder do not run and generate a runtime error on a statement where a boolean value is used. This only occurs with non English versions of Excel. Boolean values in the macro should be recorded in your language. In some cases you will find that SQL*XL statements are generated with the English True and False as values.

Cause:

When Excel records the macro it uses True and False as values for boolean SQL*XL properties. When you run a non English version of Excel, Excel's macro recorder changes the boolean values True and False to your language's versions. In some cases it does not do this and the English True or False will generate an error when you try to run the macro.

Some of the SQL*XL objects can only be resolved at runtime. SQLXL.Sql.Statements(1) is one of these. Statements(1) can be any of a number of different objects. Therefore Excel cannot determine which type Statement(1)'s properties are and will leave the boolean properties untranslated.


Resulution:

Simply replace the English True or False with the equivalents in your language.



See also: