Yaniv Posted December 28, 2006 Posted December 28, 2006 Hi all. I have a question relating to finding with scripts. I have a file with 2 tables, Table 1 and Table 2. Both tables have corresponsding fields with linked data. Here is what I would like to do. I would like to create a button in Table 1, that will copy all data from a field named "Code" in table 1 and then switch to table 2, perform a "find" and insert the data copied from "Code" in table 1. Please can someone guide me on exactly how this would be done step by step. Thanks
mr_vodka Posted December 28, 2006 Posted December 28, 2006 Both tables have corresponsding fields with linked data Does this mean that the two tables are related? Do you have keys in each table that will allow the records to be related? If so, you can just use Go to Related Record, set field [Table2::field; Table1::code] and then commit record.
Yaniv Posted December 28, 2006 Author Posted December 28, 2006 Hi John. OK, in Table 1, there is the "Code" field. Table 2 is essentially a contact tracking table so the idea is that all a supervisor would have to do is go to a client in table 1, and click a button to be taken to table 2 which has all the contacts made to that client. Forgive my ignorance, but I donot understand your instruction. I am still very new to this. I will continue to fiddle and if I figure it out myself, I will post, otherwise I will await a response on exactly how to do it. Thanks again.
T-Square Posted December 28, 2006 Posted December 28, 2006 Yaniv-- Let's assume the following structure: Table People: PeopleID (Unique AutoEnter Serial number) etc. Table Contacts: ContactID (Unique AutoEnter Serial number) PeopleID etc. A relationship between the two tables on the PeopleID will make it so that you can display only those Contact records that match the current Person (as defined by the PersonID of the record currently being viewed). You can either script this display by creating a script that has the step described by John, or you can add a portal to your layout that displays the Contact info on multiple lines on the display. I personally like this approach, as it gives you immediate basic information, and you can set it up so that the user can view fuller information if they need it. You can even have it so that users can add new contact records right from the portal... HTH, David
Yaniv Posted December 28, 2006 Author Posted December 28, 2006 Hi all. Thanks for your help... focused me in the right direction even thos I did not quite understand where you wanted me to go to complete this command. Here is what I did. I am sure there was an easier way to do it. ____________________________________ Go to Field [Dealers::Dealer Code] Copy [select; Dealers::Dealer Code] Go to Layout ["Contact Tracking"(Contact Tracking)] Enter Find Mode [] Paste [select; Contact Tracking::Dealer Code] Perform Find [] ____________________________________ Thanks again.
Recommended Posts
This topic is 6540 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now