October 10, 200817 yr I'm trying to relate one record to another via scripts. Basic structure is: Posting Layout: - Show Records from Posting - show portal records from Project Posting ID My challenge is getting the Project ID into the Posting record field to allow the portal to work. The portal process is working, but only for the first Posting in the table. More on that later. I have button "Specify Project" the purpose of which is to link a Project with the Posting. The button opens a Select Project list which contains a button next to the desired project. That button performs a script which is supposed to update the Project ID in the Posting record with the Project ID from the selected Project record. However, the update does not happen. Instead it is updating the Project ID in the first Posting record on the file. It seems like I'm missing a relationship, or I need to somehow save the identity of the Posting record and restore it before applying the update. I'd rather accomplish it via the data structure if possible. Suggestions? I have custom messages that verify that I'm getting the right Project ID to the script. The table Project Posting ID relates the Project table to the Posting table via the field Project ID.
October 10, 200817 yr If I understand this: - you run a script from the Posting layout - this opens a new window based on Projects Is the Posting ID in a global field or variable at this point? If not, how are you going to pass it into the Project record? Or is the script still running/paused?
October 10, 200817 yr Author Thanks for offering your help. If I understand this: - you run a script from the Posting layout Correct. - this opens a new window based on Projects Correct. Is the Posting ID in a global field or variable at this point? If not, how are you going to pass it into the Project record? Or is the script still running/paused? The first button stores Posting ID in a global field. However, I don't use it later in my current implemention - I'm not seeing why I would at this point. The second button (that launches the Select Project layout) stores the Project ID in a global field, then launches a script which is suppose to update the Posting record that was on the Posting Layout, with the selected Project ID.
October 10, 200817 yr If you are on a Posting layout, that has a portal showing Projects records, then you'd store the Posting ID in the Project, not v. versa.
October 10, 200817 yr Author Thanks, Tom. It looks like that might unlock it for me. Appreciate your help.
Create an account or sign in to comment