Ask Your Question
1

Libreoffice Base - Display Form based on Group Box Option selected [closed]

asked 2016-05-22 20:56:39 +0100

hmadhi gravatar image

updated 2020-07-28 21:46:13 +0100

Alex Kemp gravatar image

I have a form that contains Patient Details. I would now like to implement an Group Box so that the user can choose "Cash" or "Medical Aid". The relevant Subform must be displayed depending on what is chosen. Any ideas on how to implement this in Libreoffice Base. I am using LibreOffice version 5.1.3

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by Alex Kemp
close date 2020-07-28 21:46:23.147244

1 Answer

Sort by » oldest newest most voted
1

answered 2016-05-23 00:02:41 +0100

Ratslinger gravatar image

updated 2020-03-31 00:17:24 +0100

You cannot hide/reveal subforms. You can use macros to open different forms using a group box or buttons. Again using macros, you can make controls visible or not.

Edit 2020-03-30:

Unfortunately, the comment by @chrispdx was not seen until today while looking for something else. The lack of messages being sent is still a major problem with this site.

Here is a copy of the file mentioned in the first comment link -> HideUnhideByGroup.odb

edit flag offensive delete link more

Comments

Thanks for the feedback. Found the a sample application viz formularze_zakladki_v2 .odb at the following link http://ooo-forums.apache.org/en/forum/viewtopic.php?t=33280&p=152727. The only problem is that it is in a foreign language. Looking to do something similar if someone can maybe decipher the code.

hmadhi gravatar imagehmadhi ( 2016-05-24 09:09:58 +0100 )edit

After a quick look, this is exactly what I mentioned - Making controls visible or not. The code is utilizing the group box and cycling through each control in that group to make it visible or not. The only foreign language within are for data names. The actual code is English and needs no translation.

Ratslinger gravatar imageRatslinger ( 2016-05-24 15:30:09 +0100 )edit

There are only a few names to translate (from Polish) - przelacz = Switching, oZdarz = oEvent, oPrzyc = oButton, and ukryj_wszystko = hide_all.

Ratslinger gravatar imageRatslinger ( 2016-05-24 18:22:01 +0100 )edit

Cool thanks @Ratslinger

hmadhi gravatar imagehmadhi ( 2016-05-31 16:14:38 +0100 )edit

The link is broken to the sample application mentioned in the first comment above. Can someone please send a new link or upload that sample? Thank you.

chrispdx gravatar imagechrispdx ( 2020-01-29 23:39:23 +0100 )edit

Question Tools

1 follower

Stats

Asked: 2016-05-22 20:56:39 +0100

Seen: 667 times

Last updated: Mar 31