mathur999 Posted August 22, 2005 Posted August 22, 2005 I have two tables related, Calendar and appointments. I have records from Appointments visible in a portal in calendar. I am trying to get a script in calendar to create a new portal row and enter the fields with data from global fields in calendar. It seems to keep writing over the last portal row and not create a new row. How do you create a new portal row (record) and enter data in it? Thanks in advance..
Reed Posted August 22, 2005 Posted August 22, 2005 Do you have "allow creation of related records" checked in the relationship options?
mathur999 Posted August 22, 2005 Author Posted August 22, 2005 Hi I do have the allow creation of related records checked in the relationship. When I click in the portal on a blank line at the bottom and enter a time in the Appointment:time field it pops up a dialogue that says: "This action cannot be performed because this field is not modifiable." Yet it is a simple time field indexed but no other restrictions and can be edited in that table O.K. The field in the Calendar table is a calculation global field. I can edited and pre-existing row in the portal but I cannot create a new row without getting the above message? Any thoughts??
-Queue- Posted August 22, 2005 Posted August 22, 2005 Is the related key field in Appointments a calculation?
mathur999 Posted August 22, 2005 Author Posted August 22, 2005 Yes the related Key field in Appointments is a calculation text field. I can enter the portal manually without a script and change a row with pre-existing data but when I click on the last row for a new portal row entry and enter the data in the field it states "This action cannot be performed because this field is not modifiable." Any thoughts?
-Queue- Posted August 22, 2005 Posted August 22, 2005 Auto-creation of related records will not work if the related key field is a calculation. If the related key must be a calculation, then you could change your script to set the current key to a global (or pass it as a Script Parameter), go to a layout based on Appointments, create a new record and set its key field with the global (or SP). Then return to the Calendar layout, Commit the record, go to a related field in the portal and then to the last portal row.
Recommended Posts
This topic is 7033 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 accountSign in
Already have an account? Sign in here.
Sign In Now