?
Solved

Create Form Header/Footer In VBA

Posted on 2001-07-19
5
Medium Priority
?
1,041 Views
Last Modified: 2008-03-10
From the answers I have received, I think this extra fact might be important. I am tring to do this from another database using the access.application object.

For other properties I am using:
set frm = objaccess.forms(doc.name)
frm.recordselectors = false

when I do frm.section(formfooter).visible = true it just runs the code without error but doesn't do the job.

I am writing some code to open a form in design view and do certain formating. One thing I have come stuck on is doing the equivelant of 'Show Header/Footer' and then adding a control to the footer. If I manually show it I can then control it using code but I can't get it to show from code. Any Suggestion??
0
Comment
Question by:regodab
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 7

Accepted Solution

by:
Nosterdamus earned 800 total points
ID: 6298803
Hi regodab,

Use:

Forms!MyForm.Section(acHeader).Visible = True

Change MyForm to the real name of your form.

Hope this helps,

Nosterdamus
0
 
LVL 7

Expert Comment

by:Nosterdamus
ID: 6298806
Sorry,

Forms!MyForm.Section(acHeader).Visible

Will do...

Nosterdamus
0
 
LVL 8

Expert Comment

by:DennisBorg
ID: 6298882
regodab:

Issuing the following command should toggle the form's header/footer:

   DoCmd.RunCommand acCmdFormHdrFtr

-Dennis Borg
0
 

Author Comment

by:regodab
ID: 6301429
This does work but not quite in my situation, I have reposted the question with more details.

Thanks
0
 
LVL 8

Expert Comment

by:DennisBorg
ID: 6308664
regodab:

>This does work but not quite in my situation, I have
>reposted the question with more details.

What is "This"? More than one person had submitted a solution, so your reference to "this works but not quite in my situation" is quite ambigious.

It would be far better to submit a post explaining how "this" did not quite work for your situation so that we could submit solutions better suited for your situation.

Could you please at least provide a link to your "new" question?


-Dennis Borg
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It’s the first day of March, the weather is starting to warm up and the excitement of the upcoming St. Patrick’s Day holiday can be felt throughout the world.
The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Suggested Courses

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question