dulux Posted April 8, 2007 Posted April 8, 2007 Hi all, This is going to sound really dumb, but I have a few newb type questions that the reference material just does not seem to answer clearly. 1. I'd like to take the contents from 2 text fields in the same table and join them into one string stored in another field in the same table - first name and surname to be precise. 2. I need a button that will open another layout in 'create record mode' and create a new record in another table (I have already created the relationships) and populate it with the existing shared data. Specifically, this is for adding user records to a company database where the company data remains the same for each user. This new FM8.5 thing is really complicated, but it feels really rewarding to work with and I look forward to each new thing I learn about it. Great package. Thanks for all your time in advance Rgds Rich
Ender Posted April 8, 2007 Posted April 8, 2007 Hi Rich; Use a calculation field for your full name, like this: FirstName & " " & SurName Your Create Record button will need to perform a script, since there's more than one operation involved. The script might look like this: Set Variable [ $CompanyID ; Company::CompanyID ] Go to Layout [ Contact ] New Record/Request Set field [ Contact::CompanyID ; $CompanyID ] This will grab the CompanyID from the Company table and add the new record in the Contact table, setting the foreign key.
dulux Posted April 8, 2007 Author Posted April 8, 2007 Thanks Ender, It seems pretty straight forward - I am assuming that I cannot just copy straight from one field to another and need to use variables for everything... I am having a challenge with the script you offered, though. The last line of the companyID bit - I am getting an error that states it is expecting an operator instead of ; - any ideas? Ta for the help.
dulux Posted April 8, 2007 Author Posted April 8, 2007 No worries - I got it! I had to click specify and type in the name of the variable - previously I was typing in the whole line of code. Thanks for the assistance - happy easter!
Recommended Posts
This topic is 6500 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