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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Records in subform are not always in order

Status
Not open for further replies.

vtuda

Programmer
May 2, 2002
18
MX
I don't know what could be happening. I have a main form with a detail subform to handle an invoice. Randomly when I add a record to subform it places on top or in the middle of the rest of records but this phenomenon doesn't happen in all records of subform that belongs to another main form records.
I'm so pretty tired [bomb] to find out some pattern on this weird behavior. Some times I'm adding records on subform in the same way like those who triggers disorder but they are perfectly ordered like I entered them.

Does anybody experienced something like this?

Does relationships that I defined between tables could be making that result?

Thanks in advance.

VIANEY

 
The subform form has a RecordSource and this can be a query which can organize the order of your records after the update of a new one. If you are just using a table with the control properties of Child and Master linking fields then you really only have the ability to have the records sorted by the sort of the original table.

Try using a query in this instance and select all of the necessary records and sort them in the order that you want them displayed. Then make sure that in the main form you perform a requery of the forms subform control. This will resort them according to the underlying forms query.

Bob Scriver

Nobody believes the official spokesman... but everybody trusts an unidentified source.
Author, Bagdad Bob???

 
Thank you so much for advice!.

I'm checking subform query and I'm finding something wrong about it: Invoice Detail table is linked to Items table but it isn't necessary. So I'm going to redefine everything on it and follow your instructions.


VIANEY

 
Many thanks Bob!

I did corrections and subform is working now !!!....

Actually I commited this big mistake: I reused another Access database project where I was working but goals were so different to this one because I don't need to control an item table.

Best Regards.

VIANEY





 
Great. Glad that I could help you on this one.

Bob Scriver

Nobody believes the official spokesman... but everybody trusts an unidentified source.
Author, Bagdad Bob???

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top