I need to create a multiTab Userform which should be used to input laboratory test results (as backup plan in case of IT-issues) and generate a printable report per patient. The tabs in the form represent different areas in the lab (hematology, coagulation, clinical chemistry, etc). The report should then also have these sub-headings, if data was input into the form. For example if data were provided in the hematology and clinical chemistry tab but not in the other tabs, then the report should only habe "hematology" as sub heading and the the values provided below that.
I made the userform and the script to generate a printable template for each patient. I am able to add the values provided as shown in the images (sorry everything in German, but you get the idea):
The problem is that there will be about 150 input fields and I dont want to validate every single input seperately. I tried using a subroutine which iterates over all controls and adds only valid values into an array which then is passed to the sub adding these values onto the report. But I just can´t figure out how to format and arrange all the data in the way mentioned above.
Is there a "compact" way to solve this?