To comment on the following update, log in, then open the issue:
http://www.openoffice.org/issues/show_bug.cgi?id=115860
                 Issue #|115860
                 Summary|oSheets.getCellRangesByName("Sh.eet2.A1") fails with c
                        |.s.s.lIllegalArgumentException
               Component|Spreadsheet
                 Version|OOO330m15
                Platform|Unknown
                     URL|
              OS/Version|All
                  Status|UNCONFIRMED
       Status whiteboard|
                Keywords|
              Resolution|
              Issue type|DEFECT
                Priority|P3
            Subcomponent|code
             Assigned to|spreadsheet
             Reported by|brinzing





------- Additional comments from [email protected] Wed Dec  1 09:53:22 
+0000 2010 -------
steps to reproduce:

- open new spreadsheet
- rename "Sheet2" to "Sh.eet2"
- run macro

result: com.sun.star.lang.IllegalArgumentException

if dots "." are valid for sheet names, oSheet.getCellRangeByName()
and oSheets.getCellRangesByName() should use the *last* occuring "."
as separator for SheetName and Range.


REM  *****  BASIC  *****
OPTION EXPLICIT

Sub Main
        
        Dim oDoc as Object
        Dim oSheets as Object

        oDoc = ThisComponent
        oSheets = oDoc.getSheets()

        Dim mRanges()

        mRanges() = oSheets.getCellRangesByName("Sheet1.A1")
        MsgBox "Sheet Index: " & mRanges(0).getRangeAddress().Sheet

        ' oSheet.getCellRangeByName("Sh.eet2.A1") is also affected
        mRanges() = oSheets.getCellRangesByName("Sh.eet2.A1")
        MsgBox "Sheet Index: " & mRanges(0).getRangeAddress().Sheet

End Sub

---------------------------------------------------------------------
Please do not reply to this automatically generated notification from
Issue Tracker. Please log onto the website and enter your comments.
http://qa.openoffice.org/issue_handling/project_issues.html#notification

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to