Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Form / Subform Help

Status
Not open for further replies.

DarkOne72

Technical User
Jun 14, 2002
210
US
Hello all....I need some assistance please!
I have a form and a subform each forms record source are queries point to the repspected table (yes they are seperate tables) My problem is that I have the main form with information on it much as like in the subform and they are joined by Master and child fields of SN (which is a primary field) what I want to happen is this:
The main form shows the information and also shows the information in subform for like a repair sheet. I need a button that will (once I type stuff in the subform) automatically fill the information form the subform up to the main form and deleting the old record it is replacing and putting in the new information from the subform. Why I need it to delete the record isbecause the SN number will change and I will no longer need the one that primarily came up.

Sorry so long winded.

Thanks in advance.
 
I am sure I could write code to do that, but that like putting a band-aid on a sucking chest wound. It sounds like you have some serious normalization and table design problems. What you are asking to do is not normal database practice. You probably need to explain your tables and queries for someone to provide any assistance.
 
Here is the layout, I have a table that has items in it New) and another table that i s Repairs. When you pull up the form it has the new one in the main window and if there was a repair it shows in the subform (link by master and child of SN). Now if the itme has to be replaced which I will no longer have the item as it will be shipped off and I will NOT receive that one back, I am wanting a button that deletes the one that is in the main form (under the new items table) and at the same tame put all the information from the repair subform into the new items table as being the new one now.

Unless you have a better idea of how to accomplish this?

Thanks for the reply
 
If you truly wish to replace the existing record with the new repair, why not just edit the record on the main form, rather than using a separate form to do so?

If you are trying to keep track of all repairs/items without always having to view the outdated items, then there is no reason to ever delete a record; you should just have a field in the table that allows you to mark that record as being not the current record - you can also have a field that indicates if the item is an original or a repair. There's nothing in your description that explains why you would have two tables containing essentially the same data, although this sounds like exactly what you have.

This is why it is hard for us to attempt to offer a solution for your question; the basic principal doesn't make any sense to us.



Cheryl dc Kern
 
Basically it is for tracking purposes of the person who brought in the item to be repaired thats why there are two tables with almsot the same data.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top