https://bugs.documentfoundation.org/show_bug.cgi?id=166232
--- Comment #31 from Olivier Hallot <[email protected]> --- (In reply to Mike Kaganski from comment #9) > Some notes. > > 1. All the functions like CDbl implement *locale-specific* conversion. It is > documented in the earliest documentation available - see "Implicit and > Explicit Type Conversions" in [1]. No it is wrong that "you should just keep > one of them for decimal values and that's it". > > 2. CDec is only implemented on Windows [2]. It is not important for your > case (on Windows), but is useful to remember (just avoid it - it's not > portable). > > Now I must say, that the provided materials (the screencasts) are useless. > Please provide a *simple* code like > > Sub X > s = "1.2" > MsgBox CDbl(s) > End Sub > > or similar, that shows which specific sample values the failing code has on > input, and also specify the error that you see in result, and your > expectation. If your testing environment is different from the Windows/en-US > (fr_FR) shown in version info of comment 0, please also specify that. > > Thank you. > > [1] https://docs.oracle.com/cd/E19064-01/so7/817-1826/817-1826.pdf#page=53 > [2] > https://opengrok.libreoffice.org/xref/core/basic/source/runtime/methods1. > cxx?r=b710ba48503372ddaf10a17ce7f4f3340bc8adb8&mo=7290&fi=258#258 Given that DECIMAL is not a official STARBASIC data type and CDec() is only implemented in Windows systems I propose to hide all Help page related to CDec function. I also wonder why CDec was implemented at all. My guess is that if DECIMAL data type [2] and CDec are needed for VBA compatibility [1] then I suggest it get implemented under Option VBASupport = 1 [3] and properly documented as such in [4] [1] https://learn.microsoft.com/en-us/office/vba/language/concepts/getting-started/type-conversion-functions [2] https://learn.microsoft.com/en-us/office/vba/language/reference/user-interface-help/decimal-data-type [3] https://help.libreoffice.org/latest/en-US/text/sbasic/shared/03103350.html?&DbPAR=BASIC&System=UNIX [4] https://help.libreoffice.org/latest/en-US/text/sbasic/shared/special_vba_func.html?&DbPAR=BASIC&System=UNIX -- You are receiving this mail because: You are the assignee for the bug.
