Automate copy and paste of data from one file to another using a button and script
Hi, I am working on a data base for medical records called: “PersonKjema”. It contains information on different examinations of a given patient and also basic information such as: ID-number and Full-name.
Separately, I have other databases files to type the results of medical Test, for example:
When clicking on File>Manage>Database , I import those tests and set relationships of fields like the ID-number and Full-name in the “PersonKjema” file and vice versa. I also click on the option: “allow creations of records when…” and “delete records when…” in order to relate fields.
When opening “PersonKjema” file, I want to use a button that performs a script in order to open one of the test “FLUE TEST” (for example) and automatically take the ID-number and full name of the patient (present Record) and paste on the “FlueTest” then I will type information of the test itself.
My wrong Solution:
I set up the button to perform a script called: “OPEN FLUE TEST” and I set the script to do:
Copy [selectet; Personkjema: ID-number]
Open File [Flue Test]
But it seems not working. I have been analyzing an similar example from an old data base that we have and it works , but I am afraid , I am missing something to do this extraction of some data from the current record of a data base into a another one.
I have also added a line Paste [selectet; Personkjema: ID-number], but not improvement at all.