Active Listbox/Combobox cell name

Creating a macro - Writing a Script - Using the API (OpenOffice Basic, Python, BeanShell, JavaScript)
Post Reply
johnnyideal
Posts: 6
Joined: Wed Nov 02, 2016 1:20 am

Active Listbox/Combobox cell name

Post by johnnyideal »

Hi, I am using OO on a Win 8 and I have an invoice template that has a list-box for every line item part#. I run the same macro to insert the selected part#, description, price, etc. It current enters it in the next empty row. How could I get the cell name that contains the list-box used to select my part#. I would like to enter the data in the same row as the active list-box. I don't know what the version of OO. It was installed approx. 2 yrs ago. Any help is greatly appreciated. Thank you. :?:
OpenOffice 4.1.2 on Windows 7
User avatar
Villeroy
Volunteer
Posts: 31279
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: Active Listbox/Combobox cell name

Post by Villeroy »

YOU are the programmer of that program. So do your job and DEBUG.
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
johnnyideal
Posts: 6
Joined: Wed Nov 02, 2016 1:20 am

Re: Active Listbox/Combobox cell name

Post by johnnyideal »

That is the problem. I am not much of a programmer. I did that with the recorder.
OpenOffice 4.1.2 on Windows 7
UnklDonald418
Volunteer
Posts: 1549
Joined: Wed Jun 24, 2015 12:56 am
Location: Colorado, USA

Re: Active Listbox/Combobox cell name

Post by UnklDonald418 »

Based on the information you provided it would be very difficult for anyone to offer much help. If you upload an example perhaps then someone can help.
To determine the version right click on Help and select About Open Office.
If your problem has been solved, please edit this topic's initial post and add "[Solved]" to the beginning of the subject line
Apache OpenOffice 4.1.14 & LibreOffice 7.6.2.1 (x86_64) - Windows 10 Professional- Windows 11
johnnyideal
Posts: 6
Joined: Wed Nov 02, 2016 1:20 am

Re: Active Listbox/Combobox cell name

Post by johnnyideal »

I want to enter the selected item in the cell that the active list-box is located. I need to find which list-box was clicked and where it is anchored. Thank you :?
Attachments
INVOICE.ots
Here is my Invoice Template
(61.84 KiB) Downloaded 115 times
OpenOffice 4.1.2 on Windows 7
UnklDonald418
Volunteer
Posts: 1549
Joined: Wed Jun 24, 2015 12:56 am
Location: Colorado, USA

Re: Active Listbox/Combobox cell name

Post by UnklDonald418 »

Looking at your example I'm impressed with how far you've been able to get with this, especially since most of the macros are recorded .
But in the end you are still trying to coerce a spreadsheet to do the job of a database.
Look at [Example] Invoice Forms (without macros)
viewtopic.php?f=100&t=56006
If your problem has been solved, please edit this topic's initial post and add "[Solved]" to the beginning of the subject line
Apache OpenOffice 4.1.14 & LibreOffice 7.6.2.1 (x86_64) - Windows 10 Professional- Windows 11
johnnyideal
Posts: 6
Joined: Wed Nov 02, 2016 1:20 am

Re: Active Listbox/Combobox cell name

Post by johnnyideal »

Thank you. I actually tried a database before I did the spreadsheet, but I didn't understand queries. Maybe I can learn from your example. I would still like to go on with this spreadsheet though. :)
OpenOffice 4.1.2 on Windows 7
Post Reply