Page 1 of 1

Make Rich Text field conditionally read only?

Posted: 11 Nov 2018
by ttanner@wicresoft.com
I have some code that moves fields to read only if a condition is met. it works for all fields that I have except for rich text fields.

fd.field('ExecutiveSponsor').readonly(true);
fd.field('Business_x0020_Justification_x00').readonly(true);

in this example, executive sponsor is a person field, and business justification is a Rich Text mutli line field. i cannot get that field to read only. any advice? im hoping i am just not using code correctly.
Thanks,
Trent

Re: Make Rich Text field conditionally read only?

Posted: 12 Nov 2018
by AlexZver
Dear Trent,

Have you tried to write something in this field after that? The text input area's color doesn't become grey, but it's unavailable to make changes.

If your field still remains changeable, please try to implement "fd.field('Business_x0020_Justification_x00').readonly(true);" without any conditions.

If that doesn't help either, please provide us a screenshot of the browser console (F12).

Re: Make Rich Text field conditionally read only?

Posted: 12 Nov 2018
by ttanner@wicresoft.com
Wow, you are correct. it was read only the whole time. I will use some CSS to try and change the look of the fields to match that of other fields.