PDA

View Full Version : Sorting on a Subform with a Subdatasheet



tammyl
10-08-2009, 10:07 PM
HI,

I have a subform (datasheet view) and I've added a Subdatasheet subform so that i can use the expandable + record selectors. This is used to display the main invoice register then list the supporting documents allocated to the main invoice. It also needs to be used to ensure that no supporting document are registered twice.

I have a few problems with the Subdatasheet view;

a) When i first open the mainform with the two embedded subforms, the Subdatasheet form is displaying as expanded. How can I make sure the subdatasheet is displayed in a 'collapsed' format when opening the form.

b) When all subdatasheet records are collapsed (doing this manually with Shift+Ctrl+arrow up) and I wish to sort the subform records using the A-Z buttons in the ribbon, the subdatasheet records are then displayed as expanded.

c) I have an index setup against my table for the subdatasheet data.
As mentioned earlier this is to stop duplicate supporting doc. records being added.
Against the IndexName, Unique = Yes, testing over three fields, first field being the SubInvoiceNo (supporting document invoice number)
When in the subdatasheet view in my form, it allows me to enter the same record twice. I tried this over across multiple main invoice records and within the same invoice record.

d) Is there a way to only display the '+' expandable option if subdata records exist.

Cheers
Tammy

OBP
10-09-2009, 03:29 AM
Sorry, I never use Datasheets.
c) you can ensure Uniqueness by combining those 3 fields in to one new field and set that to "Indexed with no duplicates".