https://bugs.documentfoundation.org/show_bug.cgi?id=157279

--- Comment #7 from TISSENDIER Pierre <[email protected]> ---
(In reply to Alex Thurgood from comment #5)
> I can confirm that the preview report doesn't open with the changed
> application background colour preferences when I set it to a colour other
> than the default before loading the preview report from the ODB file.
> 
> I couldn't find where your macro was in the test ODB file in order to test
> whether execution of the macro changes the background colour.
> 
> The question remains as to why the preview report doesn't adopt the default
> application background colour even when this is set application-wide and LO
> restarted ?

"I couldn't find where your macro was in the test ODB"
Normally it is a basic macro named openreport in Standard/module1/OpenReport

Sub OpenReport
Dim oDoc As Object 
Dim oRpt As Object 

'Eventually launch Xray
With GlobalScope.BasicLibraries
        If .hasByName("XrayTool") Then 
                .loadLibrary("XrayTool")
        End If 
End With 

'connect base
ThisDataBaseDocument.CurrentController.connect()


oRpt =ThisDataBaseDocument.ReportDocuments.getByName("rptSoldeEvenement").Open 

'xray oDoc
'oRpt =oDoc.Open

oRpt.CurrentController.ViewSettings.ZoomValue=60
With oRpt.CurrentController.Frame
        .ContainerWindow.setBackground(clng("&H00FFFF80")) 'mon vert
'       .ContainerWindow.setBackground(0) 'noir
        .ContainerWindow.isMaximized=False
        .ContainerWindow.setPosSize(250,250,500,700,15)
'x,y,largeur,hauteur,flag
        .LayoutManager.HideCurrentUI=True 'pour supprimer les barres d'outils
        .LayoutManager.hideElement("private:resource/menubar/menubar") 'pour
supprimer la barre de menu
'       .LayoutManager.showElement("private:resource/menubar/menubar") 'pour
afficher la barre de menu
        .Title ="Test Background Report"

End With 

End Sub


Thank for your investigation.

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to