Hello, I'm new at OpenOffice.
I'm working with Writer, I have a table. Inside that table I have 2 ListBoxes A and B.
I want to populate the ListBox B based on the selected item of ListBox A.
The problem that I have is that i'm not able to get the ListBox control in the code inside the macro
[Solved] ListBox inside a table
-
- Posts: 3
- Joined: Fri Mar 15, 2019 2:54 pm
[Solved] ListBox inside a table
Last edited by dionisio77 on Mon Mar 18, 2019 2:14 pm, edited 1 time in total.
Openoffice 4.1.2 on Windows 7
Re: ListBox inside a table
Base does not have any "lookup fields" like MS Access. Base tables and queries show raw data. List boxes belong to input forms where they are used to represent foreign keys with a visible string and another table's primary key as value. Search this forum for "cascading listbox".
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
Re: ListBox inside a table
Please upload an ODF type sample file and your macro code here.The problem that I have is that i'm not able to get the ListBox control in the code inside the macro
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.
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.
Re: ListBox inside a table
The 6.0.6.2 is not Apache OpenOffice (there is not such version yet). That is LibreOffice. Please update your signature in this forum.OpenOffice: 6.0.6.2 on Windows 7
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.
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.
Re: ListBox inside a table
Is the attached file what you're trying to do?
- Attachments
-
- listbox example.odt
- (11.89 KiB) Downloaded 224 times
Windows 10, Openoffice 4.1.11, LibreOffice 7.4.0.3 (x64)
-
- Posts: 3
- Joined: Fri Mar 15, 2019 2:54 pm
Re: ListBox inside a table
Yes, this is what i want!JeJe wrote:Is the attached file what you're trying to do?
I was executing a macro in the lost focus event instead.
Thanks
Openoffice 4.1.2 on Windows 7
Re: [Solved] ListBox inside a table
The focus events are for when the listbox as a whole loses or gains focus.
Note - the item status changed event will fire when the selection changes - so if you use the up and down arrow keys the item will be copied too.
You could use the Mouse Button Released event... maybe with some code to check if the item has already been copied if you don't want that happening more than once.
Note - the item status changed event will fire when the selection changes - so if you use the up and down arrow keys the item will be copied too.
You could use the Mouse Button Released event... maybe with some code to check if the item has already been copied if you don't want that happening more than once.
Windows 10, Openoffice 4.1.11, LibreOffice 7.4.0.3 (x64)