N
Niklas Östergren
Hi!
Is there a way to know where a bookmark in a DAO.Recordset is?
I have opened a form (frmMemberRegistration) used a where clause (created by
an array) to open just the records I´d like to show. This where clause is
created from an array so I don´t know how many records there will be in the
recordset of the form from time to time. The underlying table´s name is
tblMember.
This form is one of 5 form´s in a wizard and I create records in several
tables on the fly before I open form´s showing what have been created. For
each tables where records are created I store the primary key´s in arrays so
I can filter form´s showing only the newly created records. This is what´s
been done here when I open this form frmMemberRegistration.
On this form I have an unbound textcontrol where I lookup the members name
so the user know which member the records displayed on the form belongs to.
Before I open this form I have created one or several records in tblPerson.
Also here I have stored the primary keys in a global array
glngarrFamilyPersonID ().
The first record in frmMemberRegistration belongs to person with primary key
glngarrFamilyPersonID (0), the second record belongs to person with primary
key glngarrFamilyPersonID (1) and so on.
Now to my Q:
Since the relationship isn´t created yet between tblPerson and tblMember I
can´´t use DLookUp or any other way to get the correct FirstName and
LastName to be displayed in the textcontrol on form frmMemberRegistration.
The only thing I have is the array holding the primary key´s and the sort
order the underlying recordset of the form is corresponding to each other.
I know, like I said, that the first and last records in the forms
recordsource belongs to the first and last index of the array
glngarrFamilyPersonID. But how do I get the rest of the records in the
underlying forms recordsource? I don´t know how many records there may be
accept if I use UBound(glngarrFamilyPersonID). But I still don´t know if I´m
in record No 2,3 or 4 in the underlying recordset of form
frmMemberRegistration.
Any help would be highly appreciated!
TIA!
// Niklas
Is there a way to know where a bookmark in a DAO.Recordset is?
I have opened a form (frmMemberRegistration) used a where clause (created by
an array) to open just the records I´d like to show. This where clause is
created from an array so I don´t know how many records there will be in the
recordset of the form from time to time. The underlying table´s name is
tblMember.
This form is one of 5 form´s in a wizard and I create records in several
tables on the fly before I open form´s showing what have been created. For
each tables where records are created I store the primary key´s in arrays so
I can filter form´s showing only the newly created records. This is what´s
been done here when I open this form frmMemberRegistration.
On this form I have an unbound textcontrol where I lookup the members name
so the user know which member the records displayed on the form belongs to.
Before I open this form I have created one or several records in tblPerson.
Also here I have stored the primary keys in a global array
glngarrFamilyPersonID ().
The first record in frmMemberRegistration belongs to person with primary key
glngarrFamilyPersonID (0), the second record belongs to person with primary
key glngarrFamilyPersonID (1) and so on.
Now to my Q:
Since the relationship isn´t created yet between tblPerson and tblMember I
can´´t use DLookUp or any other way to get the correct FirstName and
LastName to be displayed in the textcontrol on form frmMemberRegistration.
The only thing I have is the array holding the primary key´s and the sort
order the underlying recordset of the form is corresponding to each other.
I know, like I said, that the first and last records in the forms
recordsource belongs to the first and last index of the array
glngarrFamilyPersonID. But how do I get the rest of the records in the
underlying forms recordsource? I don´t know how many records there may be
accept if I use UBound(glngarrFamilyPersonID). But I still don´t know if I´m
in record No 2,3 or 4 in the underlying recordset of form
frmMemberRegistration.
Any help would be highly appreciated!
TIA!
// Niklas