[Libreoffice-bugs] [Bug 131564] New: Cannot set cell number format to percentage + 1 decimal from VBA macro (locale-dependent)
bugzilla-daemon at bugs.documentfoundation.org
bugzilla-daemon at bugs.documentfoundation.org
Wed Mar 25 11:56:25 UTC 2020
https://bugs.documentfoundation.org/show_bug.cgi?id=131564
Bug ID: 131564
Summary: Cannot set cell number format to percentage + 1
decimal from VBA macro (locale-dependent)
Product: LibreOffice
Version: Inherited From OOo
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: BASIC
Assignee: libreoffice-bugs at lists.freedesktop.org
Reporter: libreoffice at nisz.hu
CC: nemeth at numbertext.org
Blocks: 108908
Created attachment 158977
--> https://bugs.documentfoundation.org/attachment.cgi?id=158977&action=edit
Example file from Excel
Attached file contains a simple macro to set cell number format to percentage
with 1 decimal place.
This call does not work in Calc with hu-HU locale, but works with en-US locale.
Columns("B").NumberFormat = "0.0%"
Steps to reproduce:
1. Open attached xlsm file
2. Run the macro in Excel and Calc
Actual results:
Values in column B: 1 and 12,5 become in Excel 100,0% and 1250,0% and 10.0% and
125.0% in Calc
However this works correctly with en-US locale since the decimal separator is
dot there, but comma in hu-HU.
Expected results:
Macro works regardless of locale.
LibreOffice details:
Version: 7.0.0.0.alpha0+ (x64)
Build ID: bc898e2c2784e36ad4d4cdf6d962e39069d2c82d
CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: Skia/Raster; VCL: win;
Locale: hu-HU (hu_HU); UI-Language: en-US
Calc: CL
Referenced Bugs:
https://bugs.documentfoundation.org/show_bug.cgi?id=108908
[Bug 108908] [META] Visual Basic for Applications (VBA) macro issues
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20200325/061a2926/attachment.htm>
More information about the Libreoffice-bugs
mailing list