Bug 81059

Summary: Range.Value2 - unsupported method (BASIC Runtime Error '423')
Product: LibreOffice Reporter: Anton Kochkov <anton.kochkov>
Component: BASICAssignee: Not Assigned <libreoffice-bugs>
Status: RESOLVED NOTABUG QA Contact:
Severity: enhancement    
Priority: medium CC: jmadero.dev
Version: 4.3.0.2 rc   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Anton Kochkov 2014-07-08 16:31:12 UTC
It returns error on unsupported method 'Value2' in this function:

If ExportResourceHeader(RootSheet, ResourceHFileSheet, MsgSheet, CInt(RootSheet.Cells(9, 2).Value2)) = False Then
   Exit Sub
End If
Comment 1 Anton Kochkov 2014-07-08 16:34:48 UTC
From this page (http://fastexcel.wordpress.com/2011/11/30/text-vs-value-vs-value2-slow-text-and-how-to-avoid-it/):

Range.Value2

This works the same way as Range.Value, except that it does not check the cell format and convert to Date or Currency. And thats probably why its faster than .Value when retrieveing numbers.

So .Value2 really should be the default, and is definitely the one to use 99% of the time.
Comment 2 Joel Madero 2014-07-20 05:19:22 UTC
There are a whole list of unsupported things from VB - LibreOffice does not in fact support Visual Basic - we recommend users transition to Basic or Python which are supported.

That being said I am closing this as NOTABUG - don't worry though we are well aware that VB is currently not supported and maybe at some point in the future we'll fully implement VB support, this bug report isn't necessary to remind the developers that VB currently is lacking.

Thanks for your understanding, feel free to ping the user list if you need help transitioning away from VB.

I know that "NOTABUG" is a bit misleading as this was an enhancement request - it's more "we are aware of the lacking functionality with VB and it's been reported many times before so leaving this particular bug open isn't going to help anyone"

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.