[Dropped] OLE-embedded DIAGRAM X / Y - x axis labels

Creating a macro - Writing a Script - Using the API (OpenOffice Basic, Python, BeanShell, JavaScript)
Post Reply
claudio-pqn
Posts: 1
Joined: Wed Feb 14, 2024 10:05 pm

[Dropped] OLE-embedded DIAGRAM X / Y - x axis labels

Post by claudio-pqn »

Hello everyone. I made an embedded graph in writer via ole from a program. This is part of the code:

... some code ...
// DIAGRAM X / Y
oChart := oEmbebido:getEmbeddedObject() // Recupera chart insertado
diagram := oChart:createInstance("com.sun.star.chart.XYDiagram") // Crea tipo de diagrama x/y
oChart:setDiagram(diagram)
oDATOS := oChart:getData()
oDATOS:setColumnDescriptions(aEtiquetas)


I get this graph (it's correct)
ole_diagramXY.png
ole_diagramXY.png (25.81 KiB) Viewed 1124 times
I just need to put the correct names of the X coordinate (marked in green).
I worked with getXAxis(), getSecondaryYAxis() but I can't get the result
TIA
Last edited by MrProgrammer on Tue Mar 26, 2024 6:52 pm, edited 1 time in total.
Reason: Dropped: No attachment provided when requested -- MrProgrammer, forum moderator
OpenOffice 4.1 on Windows 10
User avatar
Zizi64
Volunteer
Posts: 11364
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: ole Embedded DIAGRAM X / Y - x axis labels

Post by Zizi64 »

Please upload the full macro code and an ODF type sample file here.
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
Post Reply