Weird form format

darkproject

Registered User.
Local time
Today, 21:12
Joined
May 22, 2003
Messages
20
Ok, i must have a broken version of Access or im just crap, but ive been having a problem with the data in forms.

basically when im adding names of people with either the same first name or last name, the database just links this to another person so for example

id :1 John Smith
id :2 John Reeves

The form will display two lots of ID1. It seems to be relating the same name JOHN as one record.

Although the table DOES show these two unique records. I am really really confused.

Anyone might know what is going on?

Any advice will be greatly appreicated

Cheers

Darren
 
It seems to me that you requerying your form after specifying a first name as the criteria for your recordsource and end up positioned to the first record with that name.

I concantenate sLastName & sFirst name with the index for that name as the criteria for my form record source, and then AfterUpdate requery my form to position to the desired record.
 
Hmmm

Hi there.

Thanks for your reply.

Im not quite sure what you are saying regarding the form. Let me try and explain a little more.

Im using a main form, within this form there is a tab control facility, each of these tabs hosts a subform. When i independently open up the subform tab, the data is all there, and all is fine. When i got back to the main form the subforms do not show all of the data, but a crunched down version (using duplicates) as described above.

Ive looked through my Lastname and firstname table fields, but they seem to be okay. Do i need these Indexed? If so what exactly is this doing? It looks like there is a problem with the subforms. Anyone suggest what im missing?

Cheers

Darren
 
I obviously don't understand what you are doing. Can you post a mdb with your appropriate tables, form and subforms?
 
subform explained?

Hi IIkhoutx,

Sorry for being vague, i know its difficult to help someone when you dont have the DB infront of you or understand them.

I attached an earlier version of the DB.

Basically if you open up Detail all i want the end user to do is fill out the fields on Tab1, tab 2....etc. On tab4 hosts the phonecall log, and this is a one to many relationship.

My problem is that adding similiar names seems to group them together so when they are views in this Detail form it replicates some of the data.

Cheers

Darren

Ps im not entriely sure now if my primary ket ID setup is correct.
:-(
 
attachement

sorry! Ive done a compact too...

Since filesize was too big
 
You form Detail is constructed wrong. It has a recordsource, but no fields are bound. Presumably it's bound only to cycle through the records, causing the various subforms to tumble. But you don't requery the subforms when you move to a new necord.

On event OnCurrent of your main form (event that fires when you move to a new record), requery each of the subforms. Otherwise, the subfirms stay where they were.
 
thanks

Ok thanks a lot for your help, i really appreciate you having a look.
Unfortunately im not very good with Access and i better go back to a more basic form. (without the Tabcontrol)

I didnt realise the fields needed to be bounded. I thought that A form is just a fancy version of a table (and the fields have already been defined).

I dont get what bound means using subforms....what is this and how do i go about setting this up? Also could you expand on the OnCurrent bit please.

Sorry for being so thick
 
Last edited:

Users who are viewing this thread

Back
Top Bottom