Solved Form Headers (1 Viewer)

sctb0825

Member
Local time
Today, 08:41
Joined
Dec 28, 2021
Messages
53
I've created a form header with added controls and features that I want on every form in my database.

How can I save this as a template to use on all my forms? It seems that saving in AutoFormat is not doing the trick
 

theDBguy

I’m here to help
Staff member
Local time
Today, 08:41
Joined
Oct 29, 2018
Messages
21,473
Are you talking about column headers? If not, then you may be able to use the form as a subform.
 

sctb0825

Member
Local time
Today, 08:41
Joined
Dec 28, 2021
Messages
53
Here is a screen shot of what I want. I use this same header on every form so no matter what is being done the user has immediate access to the areas that are needed instantly. I do not want to have to recreate this header for each page. I want to make a Template, ie save it for repeated use.
 

Attachments

  • Database-08.jpg
    Database-08.jpg
    30.9 KB · Views: 137

theDBguy

I’m here to help
Staff member
Local time
Today, 08:41
Joined
Oct 29, 2018
Messages
21,473
Here is a screen shot of what I want. I use this same header on every form so no matter what is being done the user has immediate access to the areas that are needed instantly. I do not want to have to recreate this header for each page. I want to make a Template, ie save it for repeated use.
Ah, like I said earlier, have you considered using it as a subform?
 

sctb0825

Member
Local time
Today, 08:41
Joined
Dec 28, 2021
Messages
53
Can you use a subform in the header? I use the rest of the form for other purposes.. for example The screenshot of the header is on a form used to setup new agents. This process might need to be interrupted however if there is an immediate need to go to the dispatch screen for example.
It is very time consuming to have to recreate that header for each form when you consider there are about 50 forms.
 

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Today, 10:41
Joined
Feb 28, 2001
Messages
27,187
Make ONE form with all the bells and whistles but NONE of the specifics. Save that form & call it George. Then when making a new form, copy George and add the specifics. Save it as the intended new form. That way you can let George carry the repetitive load. Seriously, when I did this for the U.S. Navy, I must have had about 35-40 forms that relied on the copy-template.

My prototype form had partial events pre-coded for Form _Open, _Load, _Current, _Unload, and _Close, plus _BeforeUpdate and _Error. If I was going to have command buttons with any frequency, those buttons existed already and had _Click routines that, in the template, didn't do anything - but they had error handlers. I had logos and titles in label boxes. I had things built in at the _Load event to look up user info based on determining the user from the Domain login info. I had a bunch of code ready to act as a template for common events like error-trap handler fragments just waiting to be copied (or called). Using the template, all I had to do afterwards was fill in the specifics for each unique form section - which I would have had to do anyway since they were specific... right? Doing it that way, I estimate that I shaved between 40% and 60% of the work. (Obviously, to shave off 60% meant that the particular form didn't do much.)
 

sctb0825

Member
Local time
Today, 08:41
Joined
Dec 28, 2021
Messages
53
Make ONE form with all the bells and whistles but NONE of the specifics. Save that form & call it George. Then when making a new form, copy George and add the specifics. Save it as the intended new form. That way you can let George carry the repetitive load. Seriously, when I did this for the U.S. Navy, I must have had about 35-40 forms that relied on the copy-template.

My prototype form had partial events pre-coded for Form _Open, _Load, _Current, _Unload, and _Close, plus _BeforeUpdate and _Error. If I was going to have command buttons with any frequency, those buttons existed already and had _Click routines that, in the template, didn't do anything - but they had error handlers. I had logos and titles in label boxes. I had things built in at the _Load event to look up user info based on determining the user from the Domain login info. I had a bunch of code ready to act as a template for common events like error-trap handler fragments just waiting to be copied (or called). Using the template, all I had to do afterwards was fill in the specifics for each unique form section - which I would have had to do anyway since they were specific... right? Doing it that way, I estimate that I shaved between 40% and 60% of the work. (Obviously, to shave off 60% meant that the particular form didn't do much.)
Thanks Doc Man this helps a lot.
 

Pat Hartman

Super Moderator
Staff member
Local time
Today, 11:41
Joined
Feb 19, 2002
Messages
43,275
Access has a feature that allows you to define defaults but I've never found it to be particularly useful so I also use Doc's method.
 

theDBguy

I’m here to help
Staff member
Local time
Today, 08:41
Joined
Oct 29, 2018
Messages
21,473
Can you use a subform in the header?
Sorry, not in front of a computer now, but maybe you could give it a try and let us know how it goes. Happy New Year!
 

Users who are viewing this thread

Top Bottom