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.

Automatically entering data

Featured Replies

When creating a new document in a related file with a one to many relationship how can I automatically enter the Customer ID number that links the two.

Right now, I'm copying and pasting this number using a script. I've got to believe there's a better way.

Thanks,

Kelly

------------------------------------------------------------------------

If the relationship is set to use this id field then, when you create a new record in a portal it will automatically add the id for you, because that is how it relates the information.

If you are not using a portal, then you will have to script it to add the id field.

The database will not know that when you create a new record in the second database which record it should relate to.

HTH

  • Author

Thanks Andy,

What set of instructions would you use to accomplish this?

Thanks,

Kelly

  • Author

Hi Andy,

Thanks for getting back to me. The reason that I didn't consider a portal is because the informationI need to present in this portal is not a single row but instead about 3 rows and almost takes up a large portion of a 640 x 480 screen.

Perhaps I need to give this portl thing more consideration. If YOU were going to set this up with three FM files, Customer, Publication and Options how would you do it?

Customers ---> Publications via a portal

Publications ---> Options via a portal

Is this right? Please advise. Thanks again.

- Kelly

Exactly.

You'll notice that there are two threads here talking about the same thing; that can get kind of confusing. From now on, let's try to keep single ideas in a single thread.

If I was doing this by way of a script, i would have a global field in the related file and set this first.

To do this you need a constant field auto enter data 1 in each database and then a relationship based on the constant. then you can script this.

First write the script in the related database.

Script name - New record

New Record Request

Set field [CustomerID] "Global field"

Set Field (Constantrel::Global field) , "Customer ID"

Perform Script [subscript,external] "New Record.

If you do it by way of a portal, just set allow creation of related records and it does this for you.

HTH

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.