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

Transfering data between tables in multi-tab form....

Status
Not open for further replies.

garychamberland

Technical User
Aug 29, 2001
13
0
0
US
Hello all,

I’ve built a database for a local nonprofit that has to track several services they provide in order to compile reports for funding. To facilitate the data entry I’ve created a multi-tab form to enter data into the related tables. The main part ( area above the tabs ) of the form contains the most accessed client info ( name, address, etc….) the first tab contains the balance of the client table. The remaining tabs are for the many to one related tables for services provided, classes attended and child info. The tables all include the client name as at least part of their respective key fields.

My problem is twofold.

>When entering data, the most accurate way to enter the name field is to copy and paste into the respective tab’s name field. I haven’t been successful in creating a macro for when the field gets the focus and my expression building skills leave something to be desired. Any pointers?

>Upon entering the data in the name field for any of the tabs, I get the error message “This property is read-only and cant be set” after acknowledging the information message box, the name is entered and data entry resumes as it should. What am I missing?

Any information that you could provide would be much appreciated.

Sincere thanks in advance.
Gary C.
 
If I am understanding you correctly you want to link a field in the first form to a filed in a second and third form. If this is the case


Goto the field in question on the second and third form.
In the default value
=[Forms]![Formname]![fieldname]

the square brackets to change are [Formname] and [fieldname]

what will happen here is when you open form two or three it will refer to form one fieldname [name] and the value will be the same.

Hope I understand you correctly and hope this helps :)
 
Thanks for the quick reply. This works in populating the name fields with the name in the main form BUT, I still get the error msg listed above upon entering data into the next field AND upon completion of all the fields in the record I get an " Index or primary key cannot contain a null value" Msg. and cannot get it to accept the data.

Do you have any other thoughts?

Thanks for your effort.
Gary C.
 
PS it appears that what is happening ( I may be wrong ) is this replaces all the names in the subform with the current main form name whereas we only need to add one record.

Thanx Again.
Gary C.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top