Basic: after sheets.copybyname or sheets.remove basic-variable points to wrong sheet
Bug #1379341 reported by
MMS-Prodeia
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
LibreOffice |
Fix Released
|
Medium
|
|||
libreoffice (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
This one is an upstream bug at libreoffice, so updating to a newer version of libre office should fix it!
As 14.04 is a LTS, it should get fixed.
See:
https:/
Changed in df-libreoffice: | |
importance: | Unknown → Medium |
status: | Unknown → Confirmed |
Changed in df-libreoffice: | |
importance: | Medium → Unknown |
status: | Confirmed → Unknown |
Changed in df-libreoffice: | |
importance: | Unknown → Medium |
status: | Unknown → Fix Released |
To post a comment you must log in.
basic variable = sheets. getbyname( ..)
After inserting a new sheet with sheets.copybyname before this sheet , the basic variable points to the wrong sheet, here sheetpositon -1. You get the same effect after removing a sheet, the variable points then to sheetpositon+1.
The problem is new in this LO version. A retest in LO 4.0 is OK.
REM ***** BASIC ***** ThisComponent hasbyname( "Tabellenew" ) then removebyname( "Tabellenew" )
global otabledoc as variant
Sub Main
oTableDoc=
oSheets = oTableDoc.sheets
if osheets.
osheets.
endif
Sheet1 = oSheets. GetbyName( "Tabelle1" )
oSheets = oTableDoc.sheets
'msgbox osheets.dbg_methods
osheets. copybyname( sheet1. name,"Tabellene w",0) 'because 3.Parameter = 0 --> insert the new sheet before the sheet1 Tabelle1
'if you insert the new sheet after the old sheet, everything is ok.
Sheet1. getCellByPositi on(0,0) .string= sheet1. name 'write to the sheet Tabellenew, not to the sheet Tabelle1
End Sub