MS Access Tab Control with Multiple Subforms

  Рет қаралды 25,726

Access Jitsu

Access Jitsu

Күн бұрын

An Alternative to Multiple Subforms
in Design View for Faster Load Times
In this video we will:
1. Discuss forms that have multiple tabs with subforms bound to each tab
2. Discuss how this can slow your form load time due to resource constraints at startup
3. Discuss using a tab control for navigation, but only using on subform container in order to speed up form loading
The XML and VBA in this video can be found here:
accessjitsu.com...
All of my videos organized by topic and other blog topics:
accessjitsu.com/

Пікірлер: 23
@eddie4969
@eddie4969 8 жыл бұрын
I found your project and explanation very useful and easy to follow. much appreciated.
@huytruong2026
@huytruong2026 3 жыл бұрын
Hi, your video is incredibly useful. I don't know why you haven't made any video in the last two years. If possible, could you please post more? Thank you!
@janezklun
@janezklun 9 жыл бұрын
Nice approach between tab control with subforms, Thank you for sharing
@fabig8125
@fabig8125 8 жыл бұрын
This is a incredibly useful alternative to setting up tab controls. Thank you!
@jeffreybonto4173
@jeffreybonto4173 2 жыл бұрын
Very efficient indeed! Great idea & thanks for sharing!
@Hamidali-mx8iv
@Hamidali-mx8iv 2 жыл бұрын
Great. Can we use option group to open multiple sub forms like this?
@VoMinhHai1914
@VoMinhHai1914 5 жыл бұрын
Thank you so much. I love your video so much. I hope one day, you can make tutorial video about chart in access by VBA,can't you?
@johnhuson7055
@johnhuson7055 3 жыл бұрын
This is great and really useful, however now I have the event control on the tab control, everytime a tab is clicked everything in the details section re-draws. Is there a way to stop this?
@ioannisgiannopoulos8999
@ioannisgiannopoulos8999 5 жыл бұрын
The XML and VBA can no longer be found at the referenced page. Can you please provide them again? Thank you.
@RungeCarl
@RungeCarl 3 жыл бұрын
Brilliant!!!
@scottnorman2296
@scottnorman2296 7 жыл бұрын
Great tip! Thank you!
@abeibrahim5846
@abeibrahim5846 7 жыл бұрын
Great idea, and I thing it would be great only that we have Navigation Tab!
@nancyyount2186
@nancyyount2186 4 жыл бұрын
What if I have more than one subform on a tab? I don't know anything about coding in code builder...I'm guessing this is VBA you're using? Could you demonstrate what the code would look like for, say 3 subforms on one tab?
@JohnSmith-th5zw
@JohnSmith-th5zw Жыл бұрын
I have the same issue. Were you able to get the code you were asking for? If so, can you share it? Thanks
@nancyyount2186
@nancyyount2186 Жыл бұрын
@@JohnSmith-th5zw It's been a few years since I've worked on the database I was asking about. I think the switch/case statement would be structured something like the following: Select Case Me.tabctlEval.Value Case 0 Me.SubformContainer1.SourceObject = "subfrmTab1" Me.SubformContainer2.SourceObject = "subfrmTab2" Me.SubformContainer3.SourceObject = "subfrmTab3" Case 1 Me.SubformContainer1.SourceObject = "subfrmTab4" Me.SubformContainer2.SourceObject = "subfrmTab5" Me.SubformContainer3.SourceObject = "subfrmTab6" Case 3 Me.SubformContainer1.SourceObject = "subfrmTab7" Basically, you're saying, whatever tab number I'm clicking on, I want you to show these subforms in these subcontainers. The above would be an example of if you wanted 3 subforms to show on the first 2 tabs, and then just one subform to show on the third tab. I think that would work...but not 100% sure. I ended up going a completely different route with my database structure.
@johnukos
@johnukos 7 жыл бұрын
I like this method,however my subform is not syncing with the parent as i change records in the parent. could you help with this? thanks!
@Accessjitsu
@Accessjitsu 7 жыл бұрын
When you design a form like this, where you can put different sub-forms in the same sub-form container, I think it breaks the normal way we link sub-forms to parent forms. Usually, you would use the Link Master and Child Fields settings in the property to grid to sync your forms. But I don't think this works if you switch out the sub-forms in the container. I use a function that gets the record key from somewhere on the parent form or a public variable, and I put that in the SQL (record source) that populates each sub-form that can go into that sub-form container. an example: "SELECT * FROM ReferralBackground WHERE EvaluationID=GetInitialEval(); " GetInitialEval is a public function that gets the primary key off of the parent form. I put this in the "Record Source" property of the form so it executes when the form is loaded to the sub-form container. Now if you are going to allow navigating to a different record on the parent form while the sub-form stays loaded, you'll need to put code in the parent form's "on current" event procedure that tells the sub-form to refresh itself - maybe requery. Or you can call a public function that is inside the sub-form that will cause it to refresh itself.
@johnukos
@johnukos 7 жыл бұрын
thanks for replying! I am trying to do as little coding as possible and found that using the relationships window to link the primary index of the parent table to a link field in child table does the job for me. I can see your way being more flexible, like if i were to want to have the option of changing the data source of the subform on the fly. l am using your subform container and isolated tab control method and love it!
@johnukos
@johnukos 6 жыл бұрын
haha, decided to ditch linking with relationships window after all. I tried using a query with the main form id as the criteria. The data synced fine as i changed records on the main form, I could see the data previously entered in my subform change too but when i tried to enter data it wouldnt stick..ie it wouldnt update the table. I ended up using objSubform.LinkMasterFields and objSubform.LinkChildFields to get everything working. I found a simple example of this here .....www.databasejournal.com/features/msaccess/article.php/3599781/MSAccess-Load-Subforms-Dynamically.htm
@mikeygrey9855
@mikeygrey9855 Жыл бұрын
I asked chatGPT to fix me up something like this but couldn't do it. Thanks
@BIM-Orbit
@BIM-Orbit Жыл бұрын
It didnt work for me! :( Private Sub form_Load() Me.TAB1.Value = 0 TAB1_change End Sub ---- Private Sub TAB1_change() Select Case Me.TAB1.Value Case 0 Me.SubCont.SourceObject = "00_Main-Menu" Case 1 Me.SubCont.SourceObject = "01_Project-List" Case 2 Me.SubCont.SourceObject = "02_Add-Project" Case 3 Me.SubCont.SourceObject = "03_Whiteboard" Case 4 Me.SubCont.SourceObject = "" Case 5 Me.SubCont.SourceObject = "" Case 6 Me.SubCont.SourceObject = "" Case 7 Me.SubCont.SourceObject = "" Case 8 Me.SubCont.SourceObject = "" End Select End Sub
@arundeeplotus4539
@arundeeplotus4539 5 жыл бұрын
very low sound...
@napmendoza1968
@napmendoza1968 4 жыл бұрын
Your audio is terribly low!
Access  Form With a Subform and Calculated Fields
31:58
Officeinstructor
Рет қаралды 70 М.
How To Log User Activity In Access 2013 🎓
27:13
Programming Made EZ
Рет қаралды 118 М.
Officer Rabbit is so bad. He made Luffy deaf. #funny #supersiblings #comedy
00:18
Funny superhero siblings
Рет қаралды 18 МЛН
Зу-зу Күлпаш 2. Бригадир.
43:03
ASTANATV Movie
Рет қаралды 587 М.
GIANT Gummy Worm Pt.6 #shorts
00:46
Mr DegrEE
Рет қаралды 140 МЛН
Microsoft Access 2016 Forms: Form Tab Pages
12:24
Kirt Kershaw
Рет қаралды 21 М.
57. Splitting Our Database (Programming In Microsoft Access 2013) 🎓
18:35
Programming Made EZ
Рет қаралды 181 М.
Microsoft Access A to Z:  Everything you need to know about subforms
10:06
A Better Solution Than the On Filter Event in Microsoft Access Forms
29:42
Computer Learning Zone
Рет қаралды 6 М.
How to use TAB CONTROL in Ms Access 💡
8:27
Edcelle John Gulfan
Рет қаралды 11 М.
Access 2010: Auto populate fields using a combo box in forms.
11:57
Allen Jarrett
Рет қаралды 557 М.
15. (Advanced Programming In Access 2013) Linking Parent Forms To Sub-Forms
9:03
Officer Rabbit is so bad. He made Luffy deaf. #funny #supersiblings #comedy
00:18
Funny superhero siblings
Рет қаралды 18 МЛН