July 14, 200421 yr I have a basic fundraising database for a non-profit org I'm helping. I have a set of fields defining bio info, contact info, etc. They want to have info on the spouse (in the same record), if there is one, but not to show the fields for this is there is no spouse. My thought on the way to do this was to have two layouts, and change between the single layout and the married layout based on the content of the marital status field. I created a script that does this, but I want it to run automatically. Is there any way to trigger a script on the changing of a field? I don't think there is. If not, is there any way to have my fields only show up if someone's married?
July 14, 200421 yr You can create a calculation field that determines if there is a related spouse and have it result in the serial for the record if so. Then you can put the fields in a portal based on a relationship from this calculation to the serial number. They will only display when the calculation is true. Is the spouse in the same table, or do you mark a checkbox when there is a spouse?
July 14, 200421 yr Author Assume I don't want the spouse as a separate record, but as extra fields in the first record. IE, it would look like this: First Name Last Name ... Spouse First Name Spouse Last Name Essentially, I want some fields (from the same record) to appear based on whether or not a certain value is selected from a popup menu. Eventually, I want to be able to have the ability to have the spouse be their own record or exist only as part of the first record, but I'm building up to that.
July 14, 200421 yr Okay then, create a calculation field using Case( popupfield = "value"; serial ) and create a relationship from this field to serial (serial would your unique ID field). Now create a portal using this relationship and put the spouse fields in it. Note that you would change popupfield to whatever your field is named and value to the value you desire.
Create an account or sign in to comment