Refresh calculations on sub-form - BEGINNER, Please help!

H

HeatherD25

Hi,

I have a main form, with 5 sub-forms set up on it as different tabs. I need
to be able to have the main form refresh when I click on the 5th tab (Final
Scoring) in order to calculate some scores. I put a button on the main form
to refresh, and it works, but it's not very intuitive for the user. It would
be a lot easier to have the main form refresh automatically when they click
on the 5th tab. Any suggestions??

Thanks!
Heather
 
L

Lynn Trapp

Take the code that is behind your button and put it in the Click event of
the tab page.
 
H

HeatherD25

I need to have the button on the sub-form refresh the main form. How do I
refer to the main form from a sub-form? If I put the code behind the button
 
L

Lynn Trapp

Actually, from what you said, I think you should not have to have a button
on the subform that refreshes the main form. Just putting the same code that
is behind your current refresh button in the click event of the Tab page
should do it. However, to reference the main form from the subform you would
simply do this:

Forms!YourMainForm.Refresh
 
H

HeatherD25

Thank you!! That worked to put the Forms!yourmainform.Refresh in the click
event.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top