473,606 Members | 3,113 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to navigate records without navigating subtable records

137 New Member
Scenario:
I've got a table for adding records, with a subtable for all data requirements related to that record.

I've built a 'view' form to navigate through the records, so that you can view the details of each. This includes a listbox to display the list of data requirements attached to each record.

I've made navigation buttons using the control wizard and converted them to VBA to allow more flexibility so that I can add code to them.

Problem:

I want the form to navigate through the primary table records one by one, and just display the subtable records in the listbox. Currently it navigates through each individual subtable record in the listbox before moving on to the next primary record.

For example, say I have:

Record 1
- Data Requirement a
- Data Requirement b
Record 2
- Data Requirement c
- Data Requirement d
- Data Requirement e
Record 3
- Data Requirement f

When I navigate through the records, it goes:

Record 1a
Record 1b
Record 2c
Record 2d
Record 2e
Record 3f

But what I want it to do is navigate just the primary records, so that it goes:

Record 1
Record 2
Record 3

Even if I take the listbox out, the form is still navigating the sub records off screen, as it takes 2 clicks to get through the first primary record, then 3 clicks to get through the second primary record.

Is it possible to achieve what I desire?

Please let me know if I've missed any information.

Thanks.
Dec 14 '10 #1
8 2702
mshmyob
904 Recognized Expert Contributor
Sounds like to me you created the navigation buttons in the subform and not the Main form.

Can you attach the database so we can look at it?

cheers,
Dec 14 '10 #2
Adam Tippelt
137 New Member
Navigation buttons were created in the footer of the main form, not the subform.

I've now got the form/subform working so that the listbox itself isn't navigating through each sub-record, however it's still doing it invisibly in the background, as it still takes multiple clicks to get through each record. I've also noticed that if a primary record doesn't contain any sub-records, then the form won't even navigate to these primary records, and misses them out entirely.

I've attached the areas of the database concerning this issue. This is the first Access project I've done, so apologies if the code is a mess!

Let me know if you need me to explain anything.

Thanks.
Attached Files
File Type: zip Navigate Records Problem.zip (129.7 KB, 121 views)
Dec 15 '10 #3
mshmyob
904 Recognized Expert Contributor
Adam I didn't realise you were the same person who was having the problem with the delete key also until I saw both databases. I gave you the solution for the deletion in your other post but when I saw your form and table design I didn't say anything but now I think I should.

You are not really using subforms properly.

If you want I will help you with the table design as well as the form design to help with the problems you are having.

If you want help with the table design please tell me the relationship between the 2 tables supplied - testlibrary and datarequirement s.

The way you have it set you are saying that:

Each TestLibrary can have many datarequirement s
Each datarequirement has one testlibrary

This may be correct but I just want to make sure. I thought maybe requirements (datarequiremen ts) could have the same requirement for many tests (testlibrary) but you say no and create new requirements (datarequiremen ts) for each test (testlibrary)

Could you explain what the Data in the Datarequirement s table and the testlibrary are.

cheers,
Dec 15 '10 #4
mshmyob
904 Recognized Expert Contributor
If you change your "Record Source" for your form to just your table name it works.

cheers,
Dec 16 '10 #5
Adam Tippelt
137 New Member
Ah so obvious! Thank you!
Dec 17 '10 #6
Adam Tippelt
137 New Member
To answer your other post:

Yes the relationship is supposed to be one to many, as each test may have multiple data requirements.
For example, the 'test' may be to test a drop down menu box. The data requirement would be to test every possible option within that drop down list, so that you test all the options and not just one.

Given the situation it's highly unlikely that the same data requirements would apply to more than one test. If this happens then yes under the current design the data requirement would be 'duplicated'.
I may improve this further down the line to offer an "Add new or use existing from drop down list" option for the data requirements, but for now the data requirements are always added new by the user.

Was this the only reason you thought that I was using subforms incorrectly?

Thanks.
Dec 17 '10 #7
mshmyob
904 Recognized Expert Contributor
OK then you have the correct relationship type.

Since you are just using a List box with it's own query in the subform you actually don't need the subform at all.

cheers,
Dec 17 '10 #8
Adam Tippelt
137 New Member
No I didn't think I would, however it's in there because the page originally started out as a duplicate of another, and I've just not taken the subform out.

Thanks for all your help.



EDIT: Turns out I needed the subform for other functionality anyway.
Dec 20 '10 #9

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

Similar topics

3
31932
by: Paul Neave | last post by:
Yahoo! has launched a beta of it's new mapping application: http://maps.yahoo.com/beta/ It's based in Flash, but it uses JavaScript. I'm curious about one feature, though - when you pan about the map, the URL in the address bar of your browser changes to match your current location. How have they done this? I thought calling window.location.href = "etc"; would reload the page, navigating away from the current URL. Yahoo! have...
5
15075
by: D. Dante Lorenso | last post by:
I have a simple table that I'd like to query to pull out a heirarchy from a tree relationship. What is the best way to do this without a 'CONNECT BY' clause like Oracle has? Example mytable +----------+-----------+ | child_id | parent_id |
3
3190
by: jaYPee | last post by:
anyone know how can i get a 10% random records out of 2000 records? 2000 is only an example and it will vary anytime. i want to create a report out of this 10% thanks in advance
3
2149
by: Richard | last post by:
Hey there, I have a textbox and a listbox. When a user types a number in the textbox, I want to get all the records from a MS Access DB but without reloading the page. I now have something manual and a user first must press a button to get the listbox filled with records but I want to have it done automaticly without pressing a sumbit button. I know its prolly done with javascript but thats one thing
3
1580
by: Martin Williams | last post by:
This is my first post to this group. I am currently working on a project for my Intermediate vb.net class. My project is a movie rental program, which involves displaying customer records with transaction details. The way it is set up now is that I have a group of bound text boxes to display the customer information, and a datagrid to display the transaction details. Also, I have a label to display the totals for each customer's...
1
1680
by: madhu | last post by:
Hello all, I am a bignner to vb.net I am not able to move the dataset and bind the textbox to dataset. My objective is 1) when the form loads it should display the first record. and the user should be able to move next and move previous and move
4
1691
by: jkuruvil | last post by:
I need to print a report of a bunch of records that falls between certain dates. Some records have dates and some don't. I did a UNION query to look for everything that falls between these two dates and everything that have NULL in date fields. Records get sorted in an ascending order. So, now I do see all the records, but I like to display records without dates in the end with another title. How could I do this.
0
1422
by: Ohad Weiss | last post by:
Hi all, I've once asked about that topic. but didn't get an answer. I have a dataset based on 4 tables, which have relation between them. The main table presented to the user on textboxes placed on the form, and the rest of the tables presented on textboxes placed on tabpages (tabpage for each table). Here is the code I use:
4
2319
by: abdul razak | last post by:
delete multiple records by checking checkboxes records from database use javascript
3
1440
by: dcbtux | last post by:
how to show only 11 to 20 records out of 1000 records through jdbc
0
7978
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8448
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8317
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6796
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
5987
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5470
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
3948
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4010
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1313
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.