What    |Removed                     |Added
            Summary|Inserting a variable with   |Inserting a variable with
                   |time format gives           |time format gives
                   |"Expression is faulty"      |"Expression is faulty" -
                   |                            |locale problem

--- Comment #1 from ---
Additional information.

I believe problem is with how "locale" interacts with variables.
Can now reproduce problem in both and  (but with different
effects in the two versions.)

Revised procedure.


0.  Set locale setting to Danish  (Alt-F12-Language-Language Settings -locale)
         (or any other locale that uses , before decimal numbers)
0.1 Open a document where the language of the document is set to English.
         (or any other language that uses . before decimal numbers)
1.  Ctrl-F2 – Variable tab.
2.  Select Set Variable
3.  Under Format, click on Additional Formats
4.  In ‟Format Number” dialog, select category ‟Time” and Format  ‟13:37”,
click OK
5.  In ‟Fields” dialog, give 13:30 as value.
6.  ‟Insert”

Actual result:  ** Expression is faulty **

7.  Double-click on inserted variable (or edit in Variable tab of Fields
8.  Note that value is:  0,5625  (if you used 13:30)
9.  Change "," to "."

All is right with the world again.  Apparently, the Danish locale was used to
convert 13:30 into 0,5625 -- which was inserted into the English document,
which could not interpret the number, hence "Expression is faulty"

In --

Steps 0-6 as above.
7.  Show Variable, and insert the variable you just created.

Actual result:  Inserted variable only has shading (if turned on with Ctrl-F8)
                Show Variable:  00:00

8.  As before, edit the variable field. Change , to .

Good to go...

You are receiving this mail because:
You are the assignee for the bug.
Libreoffice-bugs mailing list

Reply via email to