How do I block users from adding linked records to the main record once that main record has reached the "Stop Time" field.

  • 1
  • 1
  • Question
  • Updated 2 months ago
  • Answered
  • (Edited)
I have Tables B, C and D linked to Table A. One can only add records in Table B, C or D only through a record in Table A after saving it.

I have certain projects that needs to be closed 1 hour before the meeting. I have the project closing date/time in PST already specified in the form/record.

How do I disable users apart from the Administrator from adding records B, C or D to that particular project once the clock strikes or exceeds the project close date/time (PST). Irrespective of the users' timezone.

I have tried dynamic form rules but they aren't working.
Photo of Charan Kumar R

Charan Kumar R

  • 82 Points 75 badge 2x thumb
  • Confused

Posted 2 months ago

  • 1
  • 1
Photo of Slider

Slider

  • 1,326 Points 1k badge 2x thumb
Hello Charan, 

I would have actually recommended a form rule to hide the buttons when the condition is true, so that you can allow Admins to continue to add records. 

I would say also, that you can add a condition in the buttons formula to show "" if the conditions are met, hiding the button essentially. This would not detect user role however.

While both of these should work, I could see the formula not firing on time, and some added difficulty with timezones.  

Would you like to try a condition in your formula button?
If(Now()-tohours(1)>[Date/Time],"",$URL) 

Photo of Charan Kumar R

Charan Kumar R

  • 82 Points 75 badge 2x thumb
Wow! Condition in the button gave me exactly what I was looking for. Thanks Slider.