473,287 Members | 1,813 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,287 software developers and data experts.

How to maximize subforms to the size of the main form

I need to know how to maxinimze subforms to the size of the main form.
I have managed to do the code to maximize the main form, but it does not work on the subforms. The main form contains 6 subforms which I need to maximize within the main form (the screen size).
Manually setting the size of the subforms is frustrating as I have serval users of the front end, personnally on 3 different PCs (incl laptop). I regularly update the front end of the database, so I cannot physically reset each subform for each user's screen each time.
Michele
May 29 '10 #1
5 5654
ADezii
8,834 Expert 8TB
To the best of my knowledge, you can only make a SubForm as large as the SubForm Control that it is containied within.
May 30 '10 #2
I need the subform to automatically take the size of the mainform. Is it possible for the command to "read" the size of the maximized main form and after open command for the subform insert the size of the mazimized main form ?
I apologize for my lack of experience, I am a novice at code-writing.
May 30 '10 #3
missinglinq
3,532 Expert 2GB
What exactly are you referring to when you say "subform?" If a true subform is the same size as the main form, it would cover the main form, completely obliverating it.

Linq ;0)>
May 30 '10 #4
I have 6 subforms based on seperate tables that exist in one-many relationship to the main form. They have index tabs with which you can alternatively view them.

Main form contains patient details. It is the top plusminus 20% of screen.
Subforms contain eg lab results, visits, risk factors, sonar results etc.Bottom 80% of screen.

I have changed the Access options> current database>tabbed windows to overlapping windows, and then inserted the maximize command on the main form. This works.

After trying the same thing on the different subforms, the subforms do not open to the size of the main form (which is the screen size). I have tried this on "open" and "load" of subform, but they only open to their own size.

If maximize would not work on subforms, I would really like for the subform to read the size of the main form (the size of the screen) and copy this to set its own size to eg 100% of width and 80% of height, and not have to manually set each version of the front end for each screen.
May 30 '10 #5
OldBirdman
675 512MB
This may be an Access2007 issue, but I don't think so.

There seems to be a lot of terms used by the Original Poster(OP) as if they were interchangable. They are not.

Table - Set of similar records stored as fields
Form - Window to a table (or query) that presents the data from the table in a human-readable display
Control - One element of a form. May contain data from a table, from another source, or no data at all.

Tables can be related, but forms cannot. The perceived relationship between forms is not recognized by Access. Yes, there are wizards to look at the table relationships and construct WHERE clauses (filters) to limit the set of records that are available to a form. Once the wizard is done, the relationships are artificial. If changed incorrectly, Access presents the incorrect data.

Controls are the items on a form. They may be text boxes (textbox or label), yes/no (check boxes, radio buttons, or toggle buttons), buttons, and images. They may contain a single data item, either from the table (bound) or not (unbound). Some controls allow display of multiple items of data as a list or matrix. Listboxes, comboboxes, and subforms are examples.

To want to "Maximize" a control makes no sense. What would a form look like if the "Exit" command button were "Maximized"? For one thing, the form would be useless because there could not be any other controls visible. It would be impossible to reverse this "Maximize" because there could be no "Normal Size" button.

I suspect that what is searched for here is a form to display only the data somehow related to the data displayed in the main form. This would necessitate understanding Modal and Popup as well as Maximize and Normal to control this form (actually 6 forms). How the user is to Maximize this form is also a function of the properties of the form, whether the Maximize/Normal toggle is displayed in the upper-right corner with the Close button, etc.

OP needs to understand these issues. If she already does, then she needs to present the problem without the ambiguity currently present.
May 31 '10 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Evil | last post by:
Hi, i have a problem with a treeview and some subforms in MS Access97. I have a form with a treeview on the left side which lets me navigate thru some projects. Then on the right side, i have...
1
by: M Wells | last post by:
Hi All, I am developing an Access 2003 project application with the back end in SQL Server 2003. I have a master form that tracks projects, and several subforms on it that track various...
2
by: Jack | last post by:
Hi all, I searched the archives and found everyone happy with Stephen's MouseWheel On/Off code except for those with subforms. Stephen's page indicates that he has added code to handle subforms...
7
by: Colleyville Alan | last post by:
I have an app that uses Access to grab various PowerPoint slides using the followhyperlink command. I have set the PPT window to run in a minimized state: FollowHyperlink link Set oPres =...
0
by: Jack | last post by:
Gday everyone, I'm dearly hoping Stephen Lebans is going to update his masterpeice to stop the mouse wheel scrolling to work on subforms *he has indicated this to me but of course beggers can't...
4
by: lauren quantrell | last post by:
I have an Access 2K popup form to which I have added buttons to run DoCmd.Maximize The problem is the form opens full height on the screen, with the bottom of the form hidden under the Windows...
1
by: Brandon | last post by:
Hello there. I'm currently working on a moderately complex Visual C# windows application that I have run into a bit of a problem on. To start things off, the application has normally been run...
2
by: insomniux | last post by:
Hi, I have an Access 2000 database with one main form in which all subforms are embedded. In this form I have a timer which closes the form, detaches the linked (ODBC) tables and reopens the same...
4
by: Harlequin | last post by:
I have a question concerning the need to trigger events within a "child" subform which is itself enbedded within a master "parent" form and which is accessible via a tab in the parent form. Becuase...
3
by: =?Utf-8?B?Qm9iQWNoZ2lsbA==?= | last post by:
I give my user a button to change the properties of the size property of maximize screen size. How can I programmatically cause the maximize screen function to happen after changing the property...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Aftab Ahmad | last post by:
Hello Experts! I have written a code in MS Access for a cmd called "WhatsApp Message" to open WhatsApp using that very code but the problem is that it gives a popup message everytime I clicked on...
0
by: Aftab Ahmad | last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below. Dim IE As Object Set IE =...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.