Hello everyone. I’m trying to use the basic programming language to code a custom dialog box but can’t seem to figure out how to execute code when a button is clicked. Can someone help me with this or point me in the direction of where to find the answer?
Basically, I have a custom dialog box I made that includes a list box populated with some items. After the user selects an item from the list and clicks on the “Select” button, I want to execute some code. Problem is, I can’t figure out how to do this.
I was thinking it’d be something like the following:
oDialogModel = oDialog1.Model
oSelectModel = oSelectModel.getByName(“SelectButton”)
oSelectModel.Event(“ButtonClick”)
…execute some code
End Event
I know that code won’t work but do you get the idea? Where do I go and/or what do I need to do to get the libreoffice basic code to sense when a button within my custom dialog box is clicked and execute the appropriate code?
Thanks in advance for you time and reply.