May 22, 200223 yr contacts.db and orders.db have a relationship with the field contact as the key. HOw can i create a script/button in contacts.db that will take the current record details from conatcts.db , create a new record in orders.db and leave me with that db in the foreground with the related info?
May 22, 200223 yr Always use a unique ContactID field (usually a serial number) in relationships ... For your question: You should already have a relationship linking ContactID in Orders to ContactID in Contacts, so that all the contact's details are filled in automatically, using a lookup Create an All-to-All relationship (joining two calc fields = 1 on both sides) between Contacts and Orders Create a gID global text field in Orders Scripts: Set field (All::gID, ContactID) Perform script in Orders (see below): New Record Set field (ContactID, gID) Go to Layout (a layout with the info you want)
May 22, 200223 yr make sure that you have check the create a new record in the relationship dialog box
May 23, 200223 yr Author can you tell me more in laymen terms on this bit: using a lookup Create an All-to-All relationship how is this done? (joining two calc fields = 1 on both sides) between Contacts and Orders Create a gID global text field in Orders Scripts: Set field (All::gID, ContactID) Perform script in Orders (see below): New Record Set field (ContactID, gID) need a guided step on this!! Go to Layout (a layout with the info you want) " Maybe I'll run through my issue again: I have 2 dbs; contacts.db and orders.db they have a relationship defined on the main contact field. The contact field in the orders.db is a value list defined from the contact field in contacts.db with other related data looked up. What I want to achieve is when a user has found the contact they want in contacts.db, have a button there that when clicked opens the orders.db, creates a new record with the contact field and other related data autofilled. How would I achieve this? Cheers
Create an account or sign in to comment