Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 6069 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

(Sorry, I couldn't come up with a better subject line.)

I'm still trying to create a DVD rental system using FileMaker. Please, don't get hung up on the general structure of the tables and their relationship, unless it disallows me to do what I want.

I have two tables, Customers and Movies, which are related through the table Rentals. Rentals is another table which keeps track of the movie ID number, the customer ID number, and rental dates.

Now I want to create a simple (at least it should be) layout which will allow the user to search the Movies table for a movie name and the Customers table for a customer name and take the related movie ID and customer ID to create a new record in the Rentals table.

How do I do that?

Posted

I made a similar solution for a video rental store... What I did is the following:

- New Rental (button) -> creates a new rental entry (this you probably have already).

- Then next to the 'Member_ID' field I placed a button which opened a new 700 x 300 pixel window.

- The new window listed all members and their IDs and a search possibility.

- I hade a rect drawn over the entire record which was a button (in browse mode all fields must be blocked).

- The button had a script which:

.......... Copy 'Member_ID' from the search result

.......... Close current window

.......... Paste 'Member_ID' into the related table on the rental entry layout.

Very easy solution.

Let me know if you understood my explanation ;-).

Posted

I don't see how it could be any simpler. You're going to have to choose the other one from whichever one you're on. A dedicated layout is required for a choice, because of the button to add a Rental.

I would recommend using global fields, or script Variables to pass the values. Copy/paste is not the best way to pass data, and is very seldom necessary.

Posted

You can also do a "Set field" instead of the copy-paste method.

So when clicking on the button the script does:

- Set field 'rental::member_id' to 'member::member_id'

- Close window

- Goto field etc. (this way the related data shows right away)

Besides that, you can also do a pop-up list where the value list is 'member::member_id'. But if you have a lot members, the list gets very long.

This topic is 6069 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

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