Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

med database: display previous visit when entering data for a new visit

Featured Replies

  • Newbies

Hi everyone!

I'm relatively new to FM but I hope to learn it fast with your help...

I am creating a database to manage patients. Patients' contact info are in a table, and to simplify, the visits information are listed in another table, linked in a one to many way.

One patient will have many visits over time, and I need to figure out a way, when entering data for a visit, to display certain information from the previous visit, and also to be able to copy/paste info from one visit to another...

(I'd guess the same thinking may be already used when generating new invoices for the same customer using previous invoice info...)

Any thoughts? Thanks in advance, guys!

Joao Lopes.

Ophthalmologist. Chile.

Something like the attached?

And welcome to the forum

medical.zip

  • Author
  • Newbies

Thank you, Efen, I really appreciate your help. I will study the scripting you used to get how you did that. However, it seams that your solution is copying the "this visit" info into the "last visit" field... what I really want is to do it the other way, to copy the "last visit" info into the "this visit" field... is it easy to fix that? (so I can just repeat the process without completely understanding it and get it going... of course then I'll complete my homework...)

When I made the file I assumed that you would not need the complete text of your previous visit but rather would want to select particular sentences or sections from it.

This can be done by selecting them from the text of the previous visit - in the portal field at the bottom - and dragging and dropping (assuming this feature is turned on in your FileMaker preferences) these sentences into the top field - the findings of your current visit (for which a visit record has not been created yet).

This top field is a global field that will be the text of the current visit record - which is created when you click the arrow button (which transfers the text into the relevant field in a new record created in the visit table). This visit information then appears in the bottom portal field (the previous visit)ready for your next visit.

If you want to transfer all the previous visit information shown in the bottom field then create another script/button along the lines of:

goto field cVisitInfo (the one in the below portal)

set field info (the global field) with cVisitInfo

(as a precaution, if you have already entered some information in the top field which would be deleted by this last step then make the last step:

set field info (the global field) with cVisitInfo & ¶ & info )

If you will need to enter other information in different fields on each visit this is not the best method to use in your file.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.