optgroup help

  • Thread starter Thread starter nydia
  • Start date Start date
N

nydia

i think i'm on the right track. i have several tables and
they are all related by clientID, the main table's
clientid is autonumber and is the primary key and the
other tables clientid is number (long inte). i created a
main form (which goes with the main table) and then
created subforms for all the other tables. i put page
breaks after each table and then used the option group.
here are the following codes

const pageMain=1
const pageQuestionaire=2
const pageFollowup=3

___________________________________________

private sub form_current()
optpages=1
optpages_afterupdate

_____________________________________________
private sub optpages_afterupdate()
me.gotopage optpages


this seems to be working but if you open the main form
maximized all the forms open show maximized, how can i do
it so that all the forms open the same size, but the
questionaire form to open maximized (it has 25 questions,
so i want it to open, so that it all shows on a page)

any help is greatly appreciated
 
Nydia,

I suppose you could do something like this...

Private Sub optpages_AfterUpdate()
Me.GoToPage optpages
If Me.optpages = 1 Then
DoCmd.Maximize
Else
DoCmd.Restore
End If

Another idea for your consideration, is to put the subforms on different
tabs of a Tab control.
 
---------- "nydia said:
main form (which goes with the main table) and then
created subforms for all the other tables. i put page
breaks after each table and then used the option group.
here are the following codes

const pageMain=1
const pageQuestionaire=2
const pageFollowup=3

___________________________________________

private sub form_current()
optpages=1
optpages_afterupdate

_____________________________________________
private sub optpages_afterupdate()
me.gotopage optpages


this seems to be working but if you open the main form
maximized all the forms open show maximized, how can i do

I think a tab control on the main form with a page for each subform
would be a better solution.

Best regards
Emilia

Emilia Maxim
PC-SoftwareService, Stuttgart
http://www.maxim-software-service.de
 
Hi Nydia

When you call the Maximize method in Access, it maximizes the entire client
window, not just an individual form. If you want only one form to be
maximized, you must use its Activate and Deactivate events to call
DoCmd.Maximize and DoCmd.Restore, respectively.

Also, have you considered using a tab control to select your different
"pages"?
 
Back
Top