Question Locked

Micorsoft Access 2003 question

0 helpful
5 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

I am relatively new at Access and VBA and am trying to make a database for my local fire department. The part I am currently working on involves creating the run reports which are filled in after responding to a call. I was wanting to set it up such that when they are filling out the report, they can click on, and fill in only topics associated with the current call. For example I have information that is required for every call (addresses, dates, times, personnel) on one form. I want to continuously use that same form to add fire information (if that was the call) but not see car accident or hazmat stuff (since that wasn't the call). I have tried using the visibility feature with no real luck. Does anyone have any ideas? Thanks in advance!

Todd

5 replies

by tony hopkinson

My preferred solution would be

Have a table for the common call info and a include a type of call.
Then create a table for each type of call with the specific information relevant to the type.

Then they fill in the generic stuff, pick the type, click next and you show the right form, may be with a bit of a summary of what they entered in the general one.

The only wrinkle would be if a call could be of more than one type, but that can be solved reasonably easily.

Biggest tip I can give you for database stuff, start from the data.

Table for each type of info, then only start glueing the tables together if you can't keep them separate, or doing so causes you performance problems.

Look up master detail in access, you'll get your head round it.

by toddmehl

Thank you Tony for your advice! I was able to build a form that opened one more form. However what I am really striving to do is be able to open up multiple parts on one form (for example Car Accident AND Inuries) and manipulate both. I have also gotten a book on VBA, so I will take a look at that before I try to tackle more of this project. Thank you for your time!

Todd Mehl

by tony hopkinson

What you are really doing there is building a form on the fly depending on the data. It's do able but a good bit of code.

You could come up with a database design the that would accommodate it but if you want it all on one form and look sensible you have to hide the call type data that doesn't apply and shuffle everything up. I could do that easily in several environments but I've no idea if it's even possible in access.

by toddmehl

Tony,
From all I have read on various sites, that seems to be the consensus. I have looked at things like making it visible to expanding it on a form (which doesn't seem to work). The only other idea I have is make a set of forms that accommodate a majority of possibilities (lame, I know, since it defeats the fundamentals of Access) or just accept that there will be multiple boxes opening on one screen (just carefully place them so you have to fill them all out before you can hit the button that processes the data further). Again, I appreciate your time!

Todd Mehl

This discussion is closed to new replies.