https://bugs.freedesktop.org/show_bug.cgi?id=60065
Priority: medium
Bug ID: 60065
Keywords: regression
Assignee: [email protected]
Summary: BASIC: Can't set an object to NamedValue structure
Severity: normal
Classification: Unclassified
OS: Windows (All)
Reporter: [email protected]
Hardware: Other
Whiteboard: BSA
Status: UNCONFIRMED
Version: 4.0.0.2 rc
Component: BASIC
Product: LibreOffice
Created attachment 73916
--> https://bugs.freedesktop.org/attachment.cgi?id=73916&action=edit
Spreadsheet "NameValueBug" containing the code
Hello
Platform: Windows XP Pro
Version 4.0.0.2 (Build ID: 5991f37846fc3763493029c4958b57282c2597e)
Steps to reproduce:
1. Open the attached spreadsheet "NameValueBug.ods"
2. Tools> Macros> Run> NameValueBug> Standard> Module1> TestNameValue
Expected result: Value set to CellAddress
Actual result: Basic runtime error, Object variable not set
This is a regression (was ok in 3.6)
It is boring because this type of coding is required to programmatically set
lists box sources (setListEntrySource), or linked cells to controls
(setValueBinding), and so on.
Note: The following is the code contained in the attached spreadsheet. It is
reduced to what is necessary to highlight the bug.
option explicit
sub TestNamedValue
dim oSheet as object
dim oCell as object
dim oNamedValue as new com.sun.star.beans.NamedValue
oSheet = thiscomponent.sheets.getByIndex(0)
oCell = oSheet.getCellRangeByName("A1")
oNamedValue.Name = "BoundCell"
oNamedValue.Value = oCell.CellAddress
end sub
Regards
Pierre-Yves
Operating System: Windows XP
Version: 4.0.0.2 rc
Last worked in: 3.6.4.3 release
--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs